LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-27-2006, 10:24 AM   #1
rtaft
Member
 
Registered: Aug 2003
Posts: 85

Rep: Reputation: 15
No space left on disk


I am trying to copy several gigs of jpgs to another hard drive. It gets to about 2.5 gigs then says there is no space left, when there is. I have tried this on a 70GB NTFS partition, and a 120GB FAT32 partition. They are all being copied to a JPEG folder, so its not an issue of too many things in the root directory of a FAT partition...though that should never happen in NTFS. I can touch a file on it, write to it, I just can't copy any more JPEGs.

/dev/hdc1 115G 2.5G 113G 3% /mnt/temp
 
Old 12-27-2006, 10:40 AM   #2
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
How many files are you talking about here? Does it fail at the same point every time? At the time of failure a command line this will fail?

cp file1.jpg /mpt/temp

Have you tried creating a sub directory and copying the rest of the files there?
 
Old 12-27-2006, 11:24 AM   #3
rtaft
Member
 
Registered: Aug 2003
Posts: 85

Original Poster
Rep: Reputation: 15
Putting it in another directory works. There must be a cap on the number if files I can put into a folder. I knew there was in FAT32, but I didn't think it existed in NTFS. The trick is now to copy the images that have not already been copied to /mnt/temp/jpg to /mnt/temp/jpg2, but there are so many images, thousands...

I know I could use cp -u to only copy the images that haven't been copied, but how can I do it to a different directory. I used foremost to recover images from a hard drive, so all of the file names are <sector number>.jpg, so it is no small task to just copy the remaining files.
 
Old 12-27-2006, 12:10 PM   #4
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
You can try something like this:
Code:
for i in `ls /source`; do
  if [ ! -e /dest/$i ]; then
     cp $i /dest/new
  fi
done
It may be much slower than a cp * dest, but it would work. There are alternatives, creating file lists and using xargs, but that would be a few more lines.
 
Old 12-27-2006, 12:11 PM   #5
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
Forgot to mention that /dest/new is a previously created directory. If a new directory is not created then all the files will be copied to a new file called new.
 
Old 12-27-2006, 12:28 PM   #6
rtaft
Member
 
Registered: Aug 2003
Posts: 85

Original Poster
Rep: Reputation: 15
thanks, I ended up writing a quick java program to do it for me. That directory would only hold 32342 files, I had 8000 left to copy.
 
  


Reply



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
Cedega "Disk space required for the installation exceeds available disk space" Solved Spewdemon LinuxQuestions.org Member Success Stories 1 10-18-2007 06:19 PM
Very newbie - no disk space left, help! tbob Linux - Software 5 11-15-2005 03:12 AM
3Gb of disk space lost! Disk space problem or mother board conflicts with HDD Mistreated Linux - Hardware 4 12-06-2004 03:58 PM
easiest way to know how much disk space is left on partition el jue Linux - Newbie 2 04-07-2004 09:19 PM
"no space left on device" - But df shows free space! monita Linux - General 7 03-30-2004 01:14 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:52 AM.

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
Open Source Consulting | Domain Registration