2010年8月11日星期三

Uptime Usage of the command - system operation and guidance

REVIEW: uptime command displays the system has been running for how long, information display were: the time now, the system has been running for how long, the current number of login users, the system in the last 1 minute, 5 minutes and within 15 minutes average load.

uptime command usage is very simple: you can directly enter the uptime.

There is also a parameter-V, is used to query version. (Note the capital letter v)

[Linux @ localhost] $ uptime-V

procps version 3.2.7

[Linux @ localhost] $ uptime

Display results:

10:19:04 up 257 days, 18:56, 12 users, load average: 2.10, 2.10,2.09

Display shows:

10:19:04 / / system current time

up 257 days, 18:56 / / host has run time, time became, indicating that the more stable your machine.

12 user / / user connection, the total number of connections, not users

load average / / the system load average, statistics recently 1,5,15-minute system load average

So what is the average system load it? Average system load is run at a specific time interval, the average number of processes in the queue. If each CPU core, the number of currently active process, not more than 3, then the system performance is good. If the number of tasks for each CPU core is greater than 5, then the performance of this machine have a serious problem. If your linux host is 1 if dual-core CPU, when the Load Average note 6, when the machine has been fully used.

In addition, the following code shows how this kind of start-up time method of computing systems:


#include
#include
struct sysinfo s_info;
long uptime;
int d,h,m,s;
int main()
{
if(0==sysinfo(&s_info))
{
uptime=s_info.uptime;
d=uptime/(3600*24);
h=(uptime/3600)%24;
m=(uptime%3600)/60;
s=(uptime%3600)%60;
printf("d=%d:h=%d:m=%d:s=%d",d,h,m,s);
return 0;
}
return -1;
}

Run Results:

[xxx@wireless time]$ gcc -o uptime uptime.c
[xxx@wireless time]$ ./uptime
d=19:h=0:m=4:s=52
[xxx@wireless time]$

WindowsXP system, how to retrieve forgotten passwords

1, restart the computer, immediately after the startup screen appears, press the F8 key, select "Safe Mode with Command line."

2, run the end of the process, the system lists the system super user "administrator" and the local user "zhangbq" option menu, mouse click "administrator", enter the command line mode.

3, type the command: "net user zhangbq 123456 / add", forced to "zhangbq" user's password changed to "123456." To this add a new user (such as: user name is abcdef, password is 123456), please type "net user abcdef 123456 / add", add the following can be "net localgroup administrators abcdef / add" command will upgrade the system user Management group "administrators" of the user, and it has super rights.

4, restart the computer, select the normal mode, you can use to change the password after the "123456" Login "zhangbq" Users of the.

Use "administrator"

We know that in the process of installing Windows XP, the first work "administrator" default login will then ask create a new account, Yibianjinru Windows XP, use this Xinjian account login, and login screen in Windows XP only Chuxian created in Ye This user account does not appear "administrator", but in fact the "administrator" account still exists, and the password is blank.

When we understand this then, if forget the password, then the login screen, hold down the Ctrl + Alt key, then press and hold the Del key twice, you can appear classic logon screen, then type the user name "administrator", password is blank entry, and then modify the "zhangbp" password can be.

Analysis of common shell commands under Win7

Windows 7 Vista system upgrade is relatively large, stability, compatibility, humanity and others have more. The Windows 7 in the shell command line, it is found that many users do not have another major update, Windows 7 shell is the Windows 7 system console. For those who are familiar with the command line, the caller using the keyboard than the mouse faster and more effort. Users can use the "Shell:" Command to deploy all available resources to the project manager to open a complete many steps needed to complete the task, and use the syntax is simple. But many users do not know what shell commands, and the operation can be realized, then the next we will Win7 common shell commands under the comprehensive analysis, to help users understand the new order under the new system.

shell: Profile

This command can open the user's total catalog. In the case of conventional installation, the location is c: \ users \ username. You can also click on the Start menu system, the user name to access. The system can also visit the% userprofile% environment variable.

shell: Personal

This command can open the current user's Documents folder. You can also click the Start menu to access my documents.

shell: SendTo

This command can access the system "Send to" folder. If you access your personal folder, you will find this folder is hidden, if you try to double-click the entry, it will display an error message, through the shell command, you can normally access. This is because the shortcut is actually a jump entry, created for backward compatibility. The real SendTo folder is hidden folder in AppData number of sub-folders.

shell: Public

This command can open public shared folder. If you use a family group function, this command can be a window within the first information.

shell: Common Startup and shell: Startup

This command can show which programs start automatically when the system starts. Sometimes, when installed in the boot menu will automatically create a shortcut.

shell: ConnectionsFolder

This command displays the current network connection. This command should be to view the current network connection was the most efficient way. The usual method is to click the Network and Sharing Center, then select Change Adapter Set View.

shell: programs and the shell: Common Programs

These two commands can access the current user and the system user in the Start menu program list.

shell: AppData and the shell: Local AppData

These two commands can open Roaming Application Data (roaming application data folder) Local Application Data (the local application data folder). The two folders are not used in everyday applications that you can find, like Firefox application like this folder to store configuration information.

shell: Cookies and the shell: cache

These two commands is to check the Internet Explorer the most efficient way to store information.

shell: Profile

The root directory of the current logged-on user

shell: UsersFilesFolder

And shell: profile the same

shell: Personal

Currently logged on user's "My Documents" folder

shell: My Music

Currently logged on user's "My Music" folder

shell: My Pictures

Currently logged on user's "My Pictures" folder

shell: My Video

Currently logged on user's "My Videos" folder

shell: Contacts

Currently logged on user's Contacts folder

shell: Desktop

Currently logged on user's Desktop folder

shell: Downloads

Currently logged on user's download folder

shell: Favorites

Currently logged on user's Internet Explorer browser favorites

shell: Searches

Currently logged on user's search folders, saved search results have been stored

shell: Links

Links to the current logged-on user folder, save the Internet Explorer browser navigation panel

shell: Public

Users to access shared folders

shell: Common Desktop

Desktop Sharing Users

shell: Common Documents

Share user My Documents

shell: CommonDownloads

Shared download folder

shell: CommonMusic

Shared user's folder

shell: CommonPictures

User Pictures folder sharing