Re: Problem with su -

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Mar 6, 2012 at 12:30, Ed Greshko <Ed.Greshko@xxxxxxxxxxx> wrote:
>
> You said you have this....
>
>       bash-4.2# ls /etc/bashrc*
>       /etc/bashrc  /etc/bashrc~  /etc/bashrc.wrkng
>
> I don't know what /etc/bashrc~ since I don't have one on my system.
> Maybe move that to /tmp or something and try again?
>

Those are backup files from some editor, most likely emacs. It suggests
the OP has edited the /etc/bashrc at some point in the past.

> I also note that "ll" doesn't seem to work.  That is also troublesome
> since it would seem to indicate a problem with sourcing the files in
> /etc/profile.d.  You do have a /etc/profile file?
>
> Another thing to try....
>
> Move /etc/bashrc.wrkng back to /etc/bashrc and then "su -".  You'll have
> the "bad" prompt.  But then type ". /etc/bashrc" and see if there are
> any error messages.

I think all these problems are still related to the SELinux issue the OP
had earlier. Probably the relabel did not work completely. I would
suggest the OP to take a look at the permissions and the SELinux context
of the profile directories and rc files.

This is how it should be:

$ ls -lhd /etc/bash* /etc/profile*
-rw-r--r--. 1 root root  57K Sep  4  2011 /etc/bash_completion
drwxr-xr-x. 2 root root 4.0K Feb 28 14:30 /etc/bash_completion.d
-rw-r--r--. 1 root root 2.6K Aug 16  2011 /etc/bashrc
-rw-r--r--. 1 root root 1.8K Aug 16  2011 /etc/profile
drwxr-xr-x. 2 root root 4.0K Feb 27 10:09 /etc/profile.d


$ ls -Zd /etc/bash* /etc/profile*
-rw-r--r--. root root system_u:object_r:etc_t:s0       /etc/bash_completion
drwxr-xr-x. root root system_u:object_r:etc_t:s0       /etc/bash_completion.d
-rw-r--r--. root root system_u:object_r:etc_t:s0       /etc/bashrc
-rw-r--r--. root root system_u:object_r:etc_t:s0       /etc/profile
drwxr-xr-x. root root system_u:object_r:bin_t:s0       /etc/profile.d

# ls -lh /root/.bash*
-rw-------. 1 root root  32K Mar  4 22:55 /root/.bash_history
-rw-r--r--. 1 root root   24 Aug 10  2011 /root/.bash_logout
-rw-r--r--. 1 root root  404 Feb 19 18:11 /root/.bash_profile
-rw-r--r--. 1 root root 2.1K Mar  4 22:57 /root/.bashrc

# ls -Z /root/.bash*
-rw-------. root root system_u:object_r:admin_home_t:s0 /root/.bash_history
-rw-r--r--. root root system_u:object_r:admin_home_t:s0 /root/.bash_logout
-rw-r--r--. root root system_u:object_r:admin_home_t:s0 /root/.bash_profile
-rw-r--r--. root root system_u:object_r:admin_home_t:s0 /root/.bashrc

GL

-- 
Suvayu

Open source is the future. It sets us free.
-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org


[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux