LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-20-2011, 10:32 PM   #1
Syllinger
LQ Newbie
 
Registered: Sep 2011
Posts: 22

Rep: Reputation: 1
Meaning behind coloring in Linux filesystem?


Alright, so I'm a Linux newbie, but I've been trucking along pretty well. I have Samba all set up for file and printer sharing with different levels of user acess, and everything seems to be working perfectly.

One thing, however, is still bugging me. Yesterday, I installed a new internal hard drive formatted with the NTFS file system. I then connected another NTFS formatted drive, but this one was external. I mounted these two drives to /mnt/sdb1 and /mnt/sdc1 respectively.

When navigating to /mnt/ and doing a 'ls -l' it ended up showing me two directories, however, unlike most driectories that are presented through Putty in blue text, these directories were written in grey text with a bright green background.

I then proceeded to format the internal NTFS formatted drive, re-partitioned it, and refomatted it using the ext4 FS. After mounting the internal drive back to /mnt/sdb1 I now had the sdb1 folder showing up as i expected (blue text, no background color) but the sdc1 directory was still grey text with a green background. Logically, I assumed that this was due to the fact that the mount points were two different file systems.

Anyway, I proceeded to transfer the entire contents of sdc1 to sdb1 using the 'rsync -avh /mnt/sdb1 /mnt/sdc1' command. Again, when looking at /mnt/ I noticed that sdb1 (ext4) was written in blue text, no background, while sdc1 (NTFS) was still grey text with a green background. Finally, I navigated to /mnt/sdb1 and when viewing the directory they were all grey text with a green background.

Anyway, after that garrulous explanation, what do these colours signify? I realize that they can be altered in Putty, but I'm trying to figure out what their significance is. I've been searching online, and all I've found are articles that discuss how to change them, not what they signify.

Currently I'm using Ubuntu Server LTS 10.04, and I originally assumed that they were related to the filesystem, but now I'm leaning towards the fact that they may have something to do with permissions or access levels.

Any help would be appreciated.
 
Old 10-20-2011, 10:42 PM   #2
realbluntz
Member
 
Registered: Jun 2010
Location: the D
Distribution: arch x86_64
Posts: 57

Rep: Reputation: 3
The colors reflect file permissions.
 
1 members found this post helpful.
Old 10-20-2011, 10:53 PM   #3
jthill
Member
 
Registered: Mar 2010
Distribution: Arch
Posts: 211

Rep: Reputation: 67
The directory colors are set up by the dircolors command. I see the info node for ls doesn't really point that out very clearly, but if you go up a step you'll see it there. Do dircolors -p to get a dump with comments.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
file coloring Ribo01 Linux - Newbie 2 11-27-2010 05:44 PM
vi terminal coloring issue feetyouwell Linux - Software 1 01-05-2005 04:58 PM
DISCUSSION: Virtual Filesystem: Building a Linux Filesystem from an Ordinary File mchirico LinuxAnswers Discussion 0 10-28-2004 11:35 PM


All times are GMT -5. The time now is 08:36 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration