Modify Linux Command Prompt

In Linux, modify the environment variable PS1 (command line prompt), you can use VI to edit the/etc/profile file, and add the following at the end: Export PS1 = '[/u @/h/W]/$' You can, where/u shows the current user account,/h shows the current

Modify the Linux Startup level

#0-stop (do not set initdefault to 0)#1-single-user mode#2-multiple users, but no NFS#3-full multi-user mode#4-useless#5-X11#6-Restart (do not set initdefault to 6)# Detailed explanation of each running level:0 indicates that the machine is shut

Access NTFS partitions in Linux

  Download ntfs-3g Http://www.ntfs-3g.org/ Ntfs-3g depends on fuse (filesystem in userspace)Process dependencies firstDownload Fuse Http://fuse.sourceforge.net/ Compile Fuse>./Configure> Make> Make install Compile ntfs-3g VI decompressed

Analysis of commonly used list in Linux (4)

The following describes the splice function of the list function in Linux: 1. Static inline void _ list_splice (struct list_head * List, Struct list_head * head) { Struct list_head * First = List-> next; Struct list_head * Last = List-> Prev; Struct

Analysis of commonly used list in Linux (5)

The following describes the key function container_of in list: /** * List_entry-get the struct for this entry * @ PTR: The & struct list_head pointer. * @ Type: the type of the struct this is embedded in. * @ Member: the name of the list_struct

Linux inter-process communication: FIFO (1)

FIFO is a common saying: first in first out, first in first out, is the Data Processing Form of queues in the data structure. What we want to talk about here is also called the named pipe, which is a way of inter-process communication.   1. concept:

Linux thread synchronization (2): mutex)

In essence, mutex is a lock that provides protection for access to shared resources. 1. Initialization: In Linux, the thread mutex data type is pthread_mutex_t. Before use, initialize it: For the mutex of static allocation, you can set it to pthread_

Linux thread (1): thread Creation

1. concept: A thread is different from a process. To be precise, a process can be composed of multiple threads. A thread is an element of a process. by default, a process is composed of only one thread, which serializes the tasks to be executed by

Analysis of commonly used list in Linux (2)

1. The following describes the list insertion function: # Ifndef config_debug_list Static inline void _ list_add (struct list_head * New, Struct list_head * Prev, Struct list_head * Next) { Next-> Prev = new; New-> next = next; New-> Prev =

Linux signal (7): sigaction

The sigaction function is used to check/modify the processing action associated with the specified signal. in earlier versions of UNIX, signal was used. Later, sigaction was used. It can be seen that signal is more powerful than signal. in addition,

Linux thread synchronization (3): rwlock)

As mentioned in the first article of the thread synchronization series, read/write locks can have higher concurrency because they have three statuses. 1. features: Only one thread can occupy the read/write lock in the write mode at a time, but

LINUX multi-thread Learning (7)-implement "producer and consumer"

In the previous article, we used semaphores to achieve mutual exclusion between threads. This article uses the mutex synchronization mechanism of semaphores to implement a classic instance, that is, "producer and consumer ". 1. Briefly describe the

LINUX multi-thread Learning (5)-semaphore thread control

In the previous article, we talked about the use of mutex locks in threads to achieve mutex usage of shared resources. In addition to mutex lock, semaphores, the PV primitive mentioned in the operating system, can achieve mutex and synchronization.

Some Linux decompression commands

  Tar -C: Create a compressed file-X: Extract-T: View content-R: append an object to the end of the compressed archive object-U: update files in the original compressed package These five are independent commands, one of which must be used for

LINUX multi-thread Learning (iv) -- mutex lock thread control

As mentioned in the previous article, multiple threads in a process share the same resource and lead to a lock due to thread competition. Here, mutex is a simple locking method. This mutex has only two States: locking and unlocking. You can regard

Writing Device Drivers in Linux: a brief tutorial (1)

I recently saw a good guide on Linux kernel entry abroad, so I tried to translate it. Because it is the first time to try translation, and the English level is limited, errors are inevitable. Thank you! Since there is no time for this, it is

Writing Device Drivers in Linux: a brief tutorial (3)

"Helloworld DRIVER: loading and detaching drivers in kernel space When a device driver module is loaded into the kernel, preparations such as resetting devices, reserved RAM (reserving RAM), interruptions, and input/output ports are often

Install and configure ndk in Linux

Install and configure ndk in Linux If you need to reuse some of the previous C language programs when writing Android programs, you can consider using ndk. Since C and C ++ programming are designed, we strongly recommend that you install the eclipse

Tar commands in Linux

Tar [-cxtzjvfppn] file and directory .... Parameter:-C: Create a compressed file parameter command (create meaning)-X: unlock a compressed file parameter command-T: view files in the tarfile special attention, under the parameter, only one C/X/T

Linux modifying system environment variables (z)

The path value is a series of directories. When you run a program, Linux searches for these directories. Run the following command to view the value of path. $ Echo $ path For example, in the host, the path value of your Yogin is:

Total Pages: 5467 1 .... 3594 3595 3596 3597 3598 .... 5467 Go to: GO

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.