Linux Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsLinux Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old June 14th, 2002, 12:07 PM
dwh dwh is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Posts: 180 dwh User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 h 9 m 32 sec
Reputation Power: 8
Seemless Space reclamation

I have a photogallery system and will soon be totally out of space. Everything is on /home which has 100M left. /home2 has 5.9G available. (I have root access btw)

This is the directory structure:

~photodomainname/www/photos/userid/picname.jpg

where there are multiple userids and picnames of course. An awful lot!!

Permissions wise, "photos" is 777.
"userid" is owned by "nobody" and "drwxr--r--"
All of the "picname"s are owned by "nobody" and are "-rwxr-xr-x"

So...first I keep forgetting the command to get the total amount of space taken up recursively by ALL files underneath the "photos" directory.

Then, is there a way to make the "photos" directory to be on the other partition w/o moving it? And then doing a symbolic link? Or do I need to make a copy, then delete the original and do a symbolic link?

Any suggestion on the best way to do this? And if it isn't too much trouble, to put the commands step by step?

I know this board likes people to look up things and "think" but I'm asking for baby steps on this one because it is a production system with probably a hundred thousand live images and I don't want to make a mistake affecting tens of thousands of people (and my *** heh heh).

I once looked up how to do a symbolic link, created the link over the original file (or something), deleted it and wound up deleting the original. I'm terrified of getting this wrong and it's way too much data to properly back it up to another directory...and to make it worse, my host does not have proper backups (until next month)!!!

Thanks so much!

Last edited by dwh : June 14th, 2002 at 12:10 PM.

Reply With Quote
  #2  
Old June 17th, 2002, 03:24 PM
M.Hirsch M.Hirsch is offline
Contributing User
Dev Shed God 1st Plane (5500 - 5999 posts)
 
Join Date: Oct 2000
Location: Back in the real world.
Posts: 5,969 M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level)M.Hirsch User rank is First Lieutenant (10000 - 20000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 22 h 42 m 50 sec
Reputation Power: 184
the way (no guarantee you donīt fīup the system!!!) is:

cd /home2
cp -dpR /home/* .
// this could overwrite files that are already in /home2 !!!
// for not losing any data you should keep the old ones and delete them once you know everything works as expected:
mv /home /old_home
// and the "magic" symlink:
ln -s /home2 /home

if you donīt have a backup, you should really wait till next month. i take no responsibility for any of your actions nor do i guarantee this does not destroy all your data!!!
__________________
--
Manuel Hirsch - Linux, FreeBSD, programming, administration articles, tutorials and more.

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsLinux Help > Seemless Space reclamation


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway
Stay green...Green IT