Linux Login Exception--bash-4.2$ fault

Source: Internet
Author: User

1th ChapterThe display failure is:


the login system is displayed as: -bash-4.2$ fault

2nd ChapterHow to resolve:

Failure reason: The current user's environment variable file is missing or corrupt,

Solution: Copy the correct files to the user's home directory ,

User Home Directory template path /etc/skel/

# #复制变量到加家目录

-bash-4.2$ ll-a

Total 20

Drwxr-xr-x. 2 root root 4096 Nov 21 2014.

Drwxr-xr-x. Root root 4096 June 22 13:58.

-rw-r--r--. 1 root root (SEP): Bash_logout

-rw-r--r--. 1 root root 193 Sep. bash_profile

-rw-r--r--. 1 root root 231 Sep. bashrc

-bash-4.2$ pwd

/etc/skel

-bash-4.2$ CP. bash* ~

-bash-4.2$ ls ~-la

Total 32

drwx------4peng Peng 4096 June 22 17:07.

Drwxr-xr-x. 3 root root 4096 June 21 21:37.

-RW-------1peng Peng June 17:01. bash_history

-rw-r--r--1peng Peng June 17:07. bash_logout

-rw-r--r--1peng Peng 193 June 17:07. Bash_profile

-rw-r--r--1peng Peng 231 June 17:07. BASHRC

Drwxrwxr-x 3peng Peng 4096 June 21:38. Cache

Drwxrwxr-x 3peng Peng 4096 June 21:38. config

-bash-4.2$ Logout

[Email protected] ~]# Su-peng

Last login:wed June 17:02:01 CST on PTS/1

Weicome to Linuxedu.peng

[Email protected] ~]$

This solves the problem.


Linux Login Exception--bash-4.2$ fault

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.