| Visit Our Catalog at SteelGuitarShopper.com |

Post new topic UNIX Advice Needed
Reply to topic
Author Topic:  UNIX Advice Needed
Joey Ace


From:
Hamilton, Ontario, Canada
Post  Posted 10 Feb 2005 11:55 am    
Reply with quote

What's the terminal command to search for a hidden file or directory?

Background/Long Story:
I clone my Mac Powerbook's internal drive to an external drive, using a the "Carbon Copy Clone" utility. That's my backup stategy, and it has worked quite well in the past.

My internal 74 GB drive had about 20 GB free.

Last night while doing this, the ext HD cable become disconnected. When it was reattached the backup continued, but failed with the message that my "SOURCE DRIVE IS FULL"!

Checking the internal drive indicated that it was indeed full, but I could see no additional files.

I copied my DOCUMENTS folder to an external hard drive to free up space. When it was copying I noticed a very large file name "untitled 0001" being copied.

I suspect there's some hidden files like that are taking up my previously free 20 GB.
They were probably created by the botched clone job.

Thanks for any advice.

Joey



View user's profile Send private message Send e-mail Visit poster's website
Joey Ace


From:
Hamilton, Ontario, Canada
Post  Posted 10 Feb 2005 11:59 am    
Reply with quote

It's also worth mentioning, for you UNIX gurus who aren't familiar with Mac OS-X:

It has a teminal program that allows command line interface to the UNIX OS.

You probably already know that....
View user's profile Send private message Send e-mail Visit poster's website
Garth Highsmith

 

Post  Posted 10 Feb 2005 12:10 pm    
Reply with quote

" ls -a " will list all files, including the hidden files in your current directory.

I think Tinkertool allows one to configure the finder to display hidden files as well.
View user's profile Send private message
Joey Ace


From:
Hamilton, Ontario, Canada
Post  Posted 10 Feb 2005 12:17 pm    
Reply with quote

"current directory" !!!

That might be the key.
I tried ls-a at the root and found nothing.

We'll see tonight. My Powerbook isn't with me now.
View user's profile Send private message Send e-mail Visit poster's website
Garth Highsmith

 

Post  Posted 10 Feb 2005 1:03 pm    
Reply with quote

.

[This message was edited by Garth Highsmith on 06 January 2006 at 08:07 AM.]

View user's profile Send private message
Don Walters

 

From:
Saskatchewan Canada
Post  Posted 10 Feb 2005 3:39 pm    
Reply with quote

There are very helpful switches with ls. I use the following often:

ls -l :I always use this. ls by itself just gives you file names in columns. I like more info.

ls -la :all files with details

ls -lt :by time modified, latest first

ls -lS :by size, largest first

if you use these examples, remember case is significant.

View user's profile Send private message Send e-mail
Will Holtz


From:
San Francisco, California, USA
Post  Posted 10 Feb 2005 6:26 pm    
Reply with quote

The following will search your whole file system for the desired file and print out its location if found:
find / -name "untitled 0001" -type f -print
View user's profile Send private message Send e-mail Visit poster's website
Chris Lasher


From:
Blacksburg, VA
Post  Posted 10 Feb 2005 8:04 pm    
Reply with quote

Try
Code:
du / -h | grep '\(\([[:digit:]]\{2,\}M\)\|\([[:digit:]]\+G\)\)[[:space:]]'

to see what folders are the largest, then go into those folders and issue
Code:
ls -hl | | grep '\(\([[:digit:]]\{2,\}M\)\|\([[:digit:]]\+G\)\)[[:space:]]'

This will list any files that are 10MB or larger, starting from the directory you issue the command from. If you would like for this to look in directories lower than the current, issue -hlR instead of -hl. Also note that these commands could possibly print very many lines to your screen. I recommend that you pipe to the program 'less' to view the lines. To do so just add ' | less' to the end of those commands, like the following:
Code:
ls -hl | | grep '\(\([[:digit:]]\{2,\}M\)\|\([[:digit:]]\+G\)\)[[:space:]]' | less

You can use the up and down keys, page up and page down keys, etc. to scroll up and down. Press the 'q' key to quit and return to the prompt.

You could also have them print to a file instead using the right-angle bracket followed by the name of the file, like:
Code:
du / -h | grep '\(\([[:digit:]]\{2,\}M\)\|\([[:digit:]]\+G\)\)[[:space:]]' > mylistofbigfiles.txt


Also note that the first command starts at the very top directory, and as such, will take an a large amount of time to run if you have plenty o' Gigs worth of stuff. You may want to change the '/' part to a specific directory, like '/home/', for example.

[This message was edited by Chris Lasher on 10 February 2005 at 08:37 PM.]

View user's profile Send private message Send e-mail Visit poster's website
Jon Jaffe


From:
Austin, Texas
Post  Posted 11 Feb 2005 11:39 am    
Reply with quote

Joey,
I suspect it is one of the log files that was created. They can be managed with the Console program in the utilities folder. I have had them really bloat at times when problems have been detected. See: http://docs.info.apple.com/article.html?artnum=152036
View user's profile Send private message Send e-mail

All times are GMT - 8 Hours
Jump to:  
Please review our Forum Rules and Policies
Our Online Catalog
Strings, CDs, instruction, and steel guitar accessories
www.SteelGuitarShopper.com

The Steel Guitar Forum
148 S. Cloverdale Blvd.
Cloverdale, CA 95425 USA

Click Here to Send a Donation

Email SteelGuitarForum@gmail.com for technical support.


BIAB Styles
Ray Price Shuffles for Band-in-a-Box
by Jim Baron