One of the Linux tutorials

Source: Internet
Author: User

Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall

I believe that a lot of beginners who want to learn Linux are worried about what to look at Linux learning Tutorials Good, the following small series for everyone to collect and organize some of the more important tutorials for everyone to learn, if you want to learn more words, can go to wdlinux school to find more tutorials.

1, Linux system restart/shutdown command finishing

Reboot command:

1, reboot

2. shutdown-r now reboot (root user)

3, Shutdown-r 10 over 10 minutes automatic restart (root user use)

4, Shutdown-r 20:35 reboot at 20:35 time (root user)

If you set the reboot through the shutdown command, you can cancel the reboot with the SHUTDOWN-C command

Shutdown command:

1, halt immediately shut down

2, Poweroff immediately shut down

3. shutdown-h now shutdown (root user)

4, shutdown-h 10 10 minutes after automatic shutdown

If you are setting the shutdown via the shutdown command, you can cancel the reboot with the SHUTDOWN-C command

2. System Time Change Reason analysis

There are two types of Linux time, one is system time, and the other is hardware time (BIOS time).

Each time the system starts, it reads out the BIOS time and assigns it to the system time. The system time will then run independently and the BIOS time will not change.

In the BIOS time, there are two representations. One is expressed in localtime and one in UTC. You can view this in a specific way by hwclock–debug, which outputs the representation of the current hardware time.

The following example changes the system time in various situations:

1. When the Hwclock is set to the Utc=true in Localtime,/etc/sysconf/clock, the system time after reboot is 8 hours ahead of the BIOS time.

2. When Hwclock is set to Utc=false in Localtime,/etc/sysconf/clock, the system time does not change relative to the BIOS time after reboot

3. When Hwclock is set to Utc=true in Utc,/etc/sysconf/clock, the system time after reboot has no change relative to BIOS time

4. When Hwclock is set to Utc=false in Utc,/etc/sysconf/clock, the system time after reboot is pushed back 8 hours relative to the BIOS time.

As shown in the following illustration:

/etc/sysconf/clock Utc=true

/etc/sysconf/clock Utc=false

Hardware Time LocalTime

8 hours prior to reboot after system time relative to BIOS time

No change in system time

Hardware time UTC

No change in system time

After reboot, the system time is delayed by 8 hours relative to the BIOS time

Visible, when the type of the BIOS time setting is inconsistent with the settings in/etc/sysconf/clock, it can cause system time errors at boot time.

If a script implements time synchronization, it runs after the system is started. Although time synchronization can synchronize the system time to the correct time, due to the previous system time error setting, there will be an error time interval that may affect the program that depends on the system time.

Countermeasures: The root cause of this problem is the type of hardware time and the settings in/etc/sysconf/clock are inconsistent. So we're going to increase the synchronization of the hardware time in the time synchronization script to fix this problem.

Note:

UTC time: World coordinated Time (Universal times COORDINATED,UTC), 0 time zone

CST Time: CST Chinese Standard time utc+8:00 The China Coastal period (Beijing time), which is the localtime of the time zone we belong to.

3. About Time zone settings:

To ensure that the time is correct, the time zone should be set correctly. Set correctly only to make time better understood and other aspects of maintenance.

To set the method:

1.

To set the time zone manually:

For example: Set the time in the East eight area

Ln-sf/usr/share/zoneinfo/asia/shanghai

/etc/localtime

Edit/etc/sysconfig/clock zone= "Asia/shanghai"

2.

Setting with graphical commands

System-config-date (mostly limited to redhat and CentOS) or using Tzselect, follow the command prompt.

4, Linux system Software installation method

Linux Software Installation, there are two main

1 package Installation

2 Source Code compilation installation

Package installation In fact, is someone else or company, for a specific platform, the system version compiles well, and then pack

Source code compiled, is completely through the source code, manual hand, configuration, compilation, installation

Each has its own length and advantages

Package Installation

1 simple, convenient, fast

2 need to select different packages for specific environments

Source Code Compilation Installation

1 flexible, 17813.html "> Customizable and optimized

2 relatively complex and has a certain basic requirements for operators

3 time is also relatively long, especially some software or larger software, such as MySQL

In the software package installation, different Linux branches, the package is also different

For example, Wdos,centos,redhat use the RPM package.

Like Ubuntu,debian, these are Deb's.

But the source installation, basically all Linux, as well as UNIX are the same, in addition to the parameters

Which is better? No standards, depending on the needs and circumstances

This tutorial is excerpted from Wdlinux forum http://www.wdlinux.cn/bbs/, Welcome to Reprint ~

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.