November
11th
2009

PHP正则表达式介绍

实用技巧 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

PHP正则表达式介绍:

1.中括号

  • [0-9]匹配0-9
  • [a-z]匹配a-z小写字母
  • [A-Z]匹配A-Z大写字母
  • [a-zA-Z]匹配所有大小写字母
  • 可以使用ascii来制定更多

2.量词

  • p+匹配至少一个含p的字符串
  • p*陪陪任何包含0个或多个p的字符串
  • p?匹配任何包含0个或一个p的字符串
  • p{2}匹配包含2个p的序列的字符串
  • p{2,3}匹配任何包含2个或3个的字符串
  • p$匹配任何以p结尾的字符串
  • ^p匹配任何以p开头的字符串
  • [^a-zA-Z]匹配任何不包含a-zA-Z的字符串
  • p.p匹配任何包含p、接下来是任何字符、再接下来有又是p的字符串
  • ^.{2}$匹配任何值包含2个字符的字符串
  • (.*)匹配任何被包围的字符串
  • p(hp)*匹配任何一个包含p,后面是多个或0个hp的字符串
    阅读全文 »


November
7th
2009

网管的困惑

业界动态 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

作为网管的您一定有过这样的困惑,您会发现在自己的工作中有很多的困难不是来自于网络技术的,比方说领导的不理解,同事对于规章制度的不遵从等等。如果你刚刚跨入网管员的工作,那么你将会很快感到诸多的不快,觉得周围有太多的自以为是、玩世不恭和傲慢无礼的人。但是,当你做上一段时间网管工作之后,你就会从中体会到积累的智慧。

这里我假设企业的技术关系可以扩大和深化,并且能够由此带来重大的商业价值,但遗留的地雷却无处不在,许多爆炸是自己造成的,有时是故意的但却无法避免,因为我们似乎对那些传统的老问题,也就是人员、流程、组织和企业文化等出现的问题总是束手无策,而技术却不会给IT管理造成什么难题,它们基本上运作良好。

1 person likes this post.

November
5th
2009

Upgrade Windows 2003 DC to Windows Server 2008

电脑技术 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

windows2008

I have been using Windows Server 2003 for years and I believe it’s time to shift and try using Windows Server 2008. I decide to Upgrade my Windows Server 2003 Standard Edition Domain Controller, which is also a DNS & DHCP Server, to Windows Server 2008 Enterprise Edition. I will show you step by step how to perform an in-place upgrade for a Domain Controller from Windows Server 2003 to Windows Server 2008.


September
26th
2009

Disable the Hidden Administrative Shares

实用技巧 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

By default Microsoft Windows system automatically creates hidden “administrative shares” for its logical drives C:, D: … with share names C$, D$ … It also creates the admin$ hidden share for to the \winnt or windows folder. These shares are designed for remote access support by domain administrators. You can manually delete these shares by using our solution 1. If you delete these admin shares, they will be recreated when you reboot. To disable permanently so they will not be recreated on the next reboot, use the following procedure solution 2.

Here is a list of the default administrative shares, accessible only to administrator:

  • C$: To access to a partition or root directory. Other partitions are also accessible via their letter, followed by the character “$”.
  • ADMIN$: To access to% systemroot%, to manage a machine on the network.
  • IPC$: Allowing the communication network between processes.
  • PRINT $: Remote access to printers.

To view and manage the administrative shares of the computer, simply go to Control Panel / Administrative Tools / Computer Management / Shared Folders / Shares. Another alternative is to right click on the My Computer icon on desktop and select Manage.


September
22nd
2009

忘记root密码的解决办法

实用技巧 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

1.在开机启动的时候能看到引导目录,用上下方向键选择你忘记密码的那个系统,然后按“e”。

rootpass1

2.接下来你可以看到如下图所示的画面,然后你再用上下键选择最新的内核,然后在按“e”。

rootpass2

3.执行完上步操作后可以看到下面的画面,在rhgb quiet最后加“空格”,然后键入“single”,或者直接输入数字的“1”并回车确定。

rootpass3

4.按“b”键,重新引导系统。

5.进入到系统后就可以用熟悉的passwd root来更改root的密码了。改完后reboot即可。


September
9th
2009

Windows 2003 Error Event ID 7026

实用技巧 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

An HP Proliant server running Microsoft Windows 2003 SP2 constantly has an error at system-start. The service is i8042prt and the Event ID is 7026 with the error “The following boot-start or system-start driver(s) failed to load: i8042prt”. I found a reference to this error from Microsoft.

event7026


July
16th
2009

Autimatic Renaming Files Using a Batch File

实用技巧 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

Everyday I need to rename the backup file with date stamp in the file name, here is the batch .bat file, and I use scheduled task to run it.

@ECHO OFF

FOR /f “tokens=2 delims= ” %%D in (’echo %DATE:/=%’) DO SET DATEN=%%D

IF EXIST backup.txt RENAME backup.txt backup-%DATEN%.txt

The backup file will rename to backup-DDMMYYY.txt

If you want to rename the file name like backup-YYYYMMDD.txt, change the last command to

IF EXIST backup.txt RENAME backup.txt backup-%DATEN:~4,8%%DATEN:~0,4%.txt


July
11th
2009

WinRAR的三种安全战术

实用技巧 没有评论

评分: 很差劲不怎样还可以还不错太棒了
Loading ... Loading ...

一、拒绝利用WinRAR捆绑的恶意程序

不少木马、硬盘炸弹等恶意程序就是利用WinRAR自解压程序捆绑程序来伪装自己。那如何区别正常的自解压文件和捆绑了恶意程序的自解压文件呢?只要能发现自释放文件里面隐藏有多个文件,特别是多个可执行文件,就可以判定其中含有恶意程序。那么怎样才能知道自释放文件中含有几个文件,是哪些文件呢?

一个简单的识别方法是:用鼠标右击WinRAR自释放文件,在弹出菜单中选择“属性”,在“属性”对话框中你会发现较之普通的EXE文件多出两个标 签,分别是:“档案文件”和“注释”。单击“注释”标签,看其中的注释内容,你就会发现里面含有哪些文件了,这样就可以做到心中有数,这是识别用 WinRAR捆绑恶意程序文件的最好方法。

还有一个防范恶意程序方法,就是遇到WinRAR自解压程序不要直接运行,而是选择右键菜单中的“用WinRAR打开”,这样你就会发现该文件中到底有什么了。


1/41234