LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 11-11-2002, 10:15 PM   #1
jarrodatt
LQ Newbie
 
Registered: Nov 2002
Location: colorado
Posts: 1

Rep: Reputation: 0
Question 2nd hard drive


I have 2 hd i setup the master hd with LM9.0, running as server

I want to load all files to share on slave hd then when some one wants to download from http/ftp the files download from slave hd..

How is this done..?

please help
 
Old 11-12-2002, 02:31 AM   #2
DavidPhillips
LQ Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,163

Rep: Reputation: 58
make partitions for http and ftp on the drive with fdisk, I will call them /dev/hdb1 /dev/hdb2

I will assume apache is in /usr/local/apache
I will assume ftp is /var/ftp

make ext3 filesystems...

mke2fs /dev/hdb1
tune2fs -j /dev/hdb1

mke2fs /dev/hdb2
tune2fs -j /dev/hdb2

mount the partitions and copy the files to it...

apache...

mkdir /tmpdir
mount /dev/hdb1 /tmpdir

cd /usr/local/apache

copy files...

tar clpf - . | (cd /tmpdir; tar xpf -)

umount /tmpdir

remove the existing files in apache ( be sure you have them on the new partition first )

rm -rf /usr/local/apache/*
rm -rf /usr/local/apache/.*

mount the apache partition...

mount /dev/hdb1 /usr/local/apache

ftp....

mount /dev/hdb2 /tmpdir

cd /var/ftp

copy files...

tar clpf - . | (cd /tmpdir; tar xpf -)

umount /tmpdir

remove the existing files in ftp ( be sure you have them on the new partition first )

rm -rf /var/ftp/*
rm -rf /var/ftp/.*


mount the ftp partition...

mount /dev/hdb2 /var/ftp

edit fstab

/dev/hdb1 /usr/local/apache ext3 defaults 0 0
/dev/hdb2 /var/ftp ext3 defaults 0 0

-------------------------------------------------------------------------------------

Last edited by DavidPhillips; 11-12-2002 at 02:36 AM.
 
  


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
2nd hard Drive grabro Linux - Hardware 1 02-05-2005 05:49 AM
2nd Hard Drive snutz411 Linux - Hardware 3 03-24-2004 12:52 PM
2nd hard drive naflan Debian 4 02-22-2004 02:55 PM
2nd hard drive neo.sarcastic Linux - Hardware 4 09-22-2003 11:22 PM
2nd Hard Drive Tad Linux - Hardware 6 05-22-2003 12:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 01:53 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
Open Source Consulting | Domain Registration