Help - Search - Members - Calendar
Full Version: Disk Space
Linuxhelp > Support > Technical Support
andy1974
Since i am a newbie i dont know much about the file system of linux..ie swap...but anyhow.....i installed fedora core 1 as server on a 8gb drive and i noticed that the shareddrive says it only has 1 gb space free....is tis correct??......did it take 6.5 gb of space to install??? :S ?is it a partionting thing??i see 3 partions on the disk...i am sooooo confused :S
Robert83
Hi,

Open up a terminal window, and type df [or type df in console]...it will display available space on your partitions.


You did a full install?

I guess you allowed Fedora to automaticaly partition your drive, then it probably did a /boot 102MB
/ 7000MB [aprox] and a /swap 1000MB [aprox]


Sincerely
Robert B
Robert83
Are you using a Samba File server, is that what you mean about that shared drive?
andy1974
yes...it partitioned the drive auto......And yes a samba file server....Are you trying to say that the shared drive is in the swap partition ?? unsure.gif blink.gif wink.gif huh.gif ph34r.gif sad.gif
andy1974
Whoops yea i did a full install.....
Robert83
No....

it is located in /

some directory you shared with samba... check your /etc/samba/smb.conf

it is possible then that you only have 1GB free space left...

you could check it on the linux computer with df

and post back the results here



Sincerely
Robert B
andy1974
unsure.gif if i parted it manually how would it be?? swap = ? boot = ? on a 8 gb dirive??
ph34r.gif
andy1974
BTW....Thanks for your help......your teaching me alot smile.gif
Robert83
Oh,

and just one good advice,...even if it's a 8GB hard drive, I always partition the disk manualy, I mean If you share a drive with samba...there is this little thingie ,that you share your 7GB / , and if you got only 1GB free space, and your users are uploading, your linux computer may run out of space...and that is somethig you wouldn't want...

So I would definetly use a seperate partition for any shared drives, and a small seperate parition [40MB] for the config files just in case [I had some bad experiences with Automatic Partition, when it came to doing some Distro changes].

Also choosing the Server during the fedora installation [where it asks "what will this computer be?". There is no need
to install it with a FULL install [unless you wan't to try out everything].


Sincerely
Robert B
Robert83
Hi,

I would do it like this [with a 8GB hard drive]

1. /boot 50MB
2. / 4000MB [and NOT that full install, use server install, you get that choice while installing Fedora]
[but if your familiar with the console you could do a minimal install, and use apt-get to install samba, and modify
the /etc/samba/smb.conf as you please with a editor, emacs , vim , mc...]
3. /share 3000MB [seperate partition for your samba
4. /config 50MB [backup for your config files , and other REALLY important stuff]
5. use swap for the rest 900MB aprox, you could use a little less for the / partition to make swap 1024MB...[if you have 512MB ram]

Sincerely
Robert B
andy1974
Here are the results of df


[root@JACOB root]# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/hda2 6989116 5639288 994792 86% /
/dev/hda1 101086 8359 87508 9% /boot
none 94340 0 94340 0% /dev/shm
Robert83
Hi,

remove some of your packages [add & remove packages] , you probably don't need Compilers, kernel development stuff...and games, both kde and gnome [only use gnome(easier) or kde(not that easy, I don't like it somehow...but feel free to try)] ... remove packages that are not needed .


Sincerely
Robert B
andy1974
ok ....i think i will invest in a larger drive too wink.gif
Robert83
That is another possibility smile.gif

A 80GB would do just fine , you could put a lot of stuff on it , and it is currently [at least here in SCG] the best buy.

/boot 100MB
/ 10000MB
/share 1 /30000MB
/share 2 /30000MB [but you can have one if you like, one share]
/backup /8000MB
/swap


Sincerely
Robert B
andy1974
Yea That sounds real good....so did you send me the 80 gb drive yet, when should i be looking for it to arrive?? wink.gif....lol...i have defintly camr to the right place for help ....you guys are GREAT teachers....i almost scraped my first linux project but you guys changed my mind to keep trying biggrin.gif
andy1974
ok .....well i have another 8gb drive is it possable to add that drive as a slave on ide 2. and format the drive and use it as a share drive as well?....money allways seems to be a factor in the game of life.. blink.gif wink.gif
hughesjr
Money can be an issue smile.gif

Just for reference, I got a new 120gb drive (WesternDigital, ATA133, 8mb cache) on EBay for $65 plus $10 for shipping...

You can add the drive to the computer...

If it is Primary slave, it will be hdb ... If secondary master, it will be hdc ... if it is secondary slave, it will be hdd.

With the new drive installed, boot linux.

Issue the command:

fdisk /dev/hdb <--(or hdc, hdd as appropriate ... make sure NOT to do /dev/hda {your current linux drive})

you will now be at the fdisk prompt ... commands are followed by pressing the enter key (just like at the command prompt).

You can see a list of all commands by pressing m

OK, fisrt thing to do is remove any old partitions (I assume you want to erase this drive and use all the space ... if not, we'll do something else).

Use the command p to print the current partition table.

Now use the command d to remove all partitions (one at a time).

when d no longer works (all partitions are deleted), use the command n to create a new partition...pick primary partiton and if it asks, pick number 1, then accept the defaults for starting and stopping sectors (1 to the end of the drive).

now print the partition table using p ... it should have 1 type 83 (Linux) partition and nothing else. If that is what you want, press w to write these changes (if something isn't right, you can use q to exit without writing changes ... so until you specify w for write, no changes have been made).

Now do fdisk -l ... {that is a lower case l}. You should see 2 drives (once with three partitions ... your boot drive ... once with 1 partition, the new drive).

OK ... we are ready to make a file system on the new drive ... I recommend ext3 for FedoraCore1:

the command to make a new ext3 file system is:

mke2fs -j /dev/hdb1 <--(use hdc1 or hdd1 ... whichever new partition you created)

then change the checks so there are no mounting scans:

tune2fs -c0 -i0 /dev/hdb1
(those are zero's and not O's after -c and -i)

Now you can mount the new drive ... I always mount drives in mount. First, you need to make a directory to mount it in ... I'll call it hdb (if it is /dev/hdc or hdd, you can substitute hdc or hdd)

so ...

mkdir /mnt/hdb

now we want to mount the new drive:

mount -t ext3 /dev/hdb /mnt/hdb

now the command:

df -h

should show a new drive at /mnt/hdb
---------------
To make the drive mount at boot time automatically, do this:

edit /etc/fstab and add this line (I would put it under the other mounts like / and /boot, but above any /proc or usb mounts....)

/dev/hdb1 /mnt/hdb ext3 defaults,user 1 1

(you would substitute hdc or hdd as applicable)

reboot and see if it mounts...

do df -h after logging in...

If it is mounted, you can setup a share and point it to /mnt/hdb ...

when you want to put stuff in there, you put it in /mnt/hdb
andy1974
well i got to the part where i mount the drive and i got this


[root@JACOB root]# mount -t ext3 /dev/hdd /mnt/hdd
mount: wrong fs type, bad option, bad superblock on /dev/hdd,
or too many mounted file systems
[root@JACOB root]#
dry.gif
andy1974
is there a gui programs that does good disk managment??? such as formating and mounting?? i am a gui person (can ya tell) lol......i LOVE LINUX THO......lol
i suck at code
ph34r.gif
Hemant
GO to:


gnome-main-menu->system tools->Disk Managment


this tool will probably end your search for GUI disk managment tool.
But the tool is not very advanced.You can format..and mount partitions and devices using this.
andy1974
dry.gif yea i seen the tool ....but i dont see the new drive...i am having mount probs......this is what i am getting

[root@JACOB root]# mount -t ext3 /dev/hdd /mnt/hdd
mount: wrong fs type, bad option, bad superblock on /dev/hdd,
or too many mounted file systems
[root@JACOB root]#
Robert83
Hi,

what does fdisk -l show?


Sincerely
Robert B
andy1974
it shows both drives hda and hhd ..........hhd is the new drive with the ext3 filesystem.....
Hemant
Few things...
You do need not to specify the filesystem type for mounting native file systems..(i mean Linux filesystem).I think the use is redundant.
i do not think this will cause any problems..but just drop that option.

Second..
drives usually have names like.../dev/hda1..../dev/hda6

What do you mean by /dev/hdd

I think you ar using wrong drive number.
andy1974
yea sorry its /dev/hdd1
andy1974
and i was using these instructions

Issue the command:

fdisk /dev/hdb <--(or hdc, hdd as appropriate ... make sure NOT to do /dev/hda {your current linux drive})

you will now be at the fdisk prompt ... commands are followed by pressing the enter key (just like at the command prompt).

You can see a list of all commands by pressing m

OK, fisrt thing to do is remove any old partitions (I assume you want to erase this drive and use all the space ... if not, we'll do something else).

Use the command p to print the current partition table.

Now use the command d to remove all partitions (one at a time).

when d no longer works (all partitions are deleted), use the command n to create a new partition...pick primary partiton and if it asks, pick number 1, then accept the defaults for starting and stopping sectors (1 to the end of the drive).

now print the partition table using p ... it should have 1 type 83 (Linux) partition and nothing else. If that is what you want, press w to write these changes (if something isn't right, you can use q to exit without writing changes ... so until you specify w for write, no changes have been made).

Now do fdisk -l ... {that is a lower case l}. You should see 2 drives (once with three partitions ... your boot drive ... once with 1 partition, the new drive).

OK ... we are ready to make a file system on the new drive ... I recommend ext3 for FedoraCore1:

the command to make a new ext3 file system is:

mke2fs -j /dev/hdb1 <--(use hdc1 or hdd1 ... whichever new partition you created)

then change the checks so there are no mounting scans:

tune2fs -c0 -i0 /dev/hdb1
(those are zero's and not O's after -c and -i)

Now you can mount the new drive ... I always mount drives in mount. First, you need to make a directory to mount it in ... I'll call it hdb (if it is /dev/hdc or hdd, you can substitute hdc or hdd)

so ...

mkdir /mnt/hdb

now we want to mount the new drive:

mount -t ext3 /dev/hdb /mnt/hdb

now the command:

df -h

should show a new drive at /mnt/hdb
---------------
To make the drive mount at boot time automatically, do this:

edit /etc/fstab and add this line (I would put it under the other mounts like / and /boot, but above any /proc or usb mounts....)

/dev/hdb1 /mnt/hdb ext3 defaults,user 1 1

(you would substitute hdc or hdd as applicable)

reboot and see if it mounts...

do df -h after logging in...

If it is mounted, you can setup a share and point it to /mnt/hdb ...

when you want to put stuff in there, you put it in /mnt/hdb
Hemant
So you haven't partitioned ..you new harddrive...So i guess..it is slave..then try this command

#mount /dev/hdd1 /mnt/hdd

but if you are using a new harddrive..then before mounting it..you have have to make ext3 filesystem..on it..

So first of all you use
CODE
# fdisk /dev/hdd //run fdisk on /dev/hdd
Now on fdisk command prompt. type
# t //to change the id of the drive.
# L //to list of IDS.


I think 83 is the id for ext3 filesystems..now use w command to save you changes and exit fdisk.on fdisk prompt you can use m to see help.

Now run parted
# parted
Not on parted prompt..
# mkfs <drive_label> ext3..


But you have to upgrade parted before..attempting to create ext3 filesystem.The version i was using with Redhat-9.0 doesn't support creation of ext3 filesystem.But very strangely option was still there.

Now after that you can either mount your hdd manually or put a entry in /etc/fstab
andy1974
ok i will retry to get it to work..
andy1974
when i run those commands it says permision denied
andy1974
after drive is mounted what would be the procedure for adding the share in smb.conf
Hemant
Login in to single...user mode..for this.
Robert83
Hi,

here is a example smb.conf file [please keep your smb.conf file as short as possible, since it's accessed regulary, and the longer it is, the longer it takes to read, and thus will result in slower samba server]

CODE
[global]
workgroup=test
server string= Test server
printing = cups
printcap name = /etc/printcap
load printers = Yes
log file = /var/log/samba/log.%m
max log size = 50
security = SHARE

[i550]
comment = Cannon i550
path = /var/spool/samba
browseable = Yes
printable = Yes
guest ok = Yes
use client driver = Yes
print command  = lpr -l -r -P%p %s

[C]
comment = Test Drive C
path = /disk2
guest ok = Yes
printable = no
create mask = 0777


workgroup --> you enter your own workgroup here , for example COM,HOME,MYCOMPANY etc...
server string --> the server will be visible in the network neighbourhood with the specified name

[i550] ---> will be visible in the network as i550
comment ---> with the following comment
guest ok ---> anyone can print
use client driver ---> WinXP has problems [win2000 also] if this is not set to Yes
print command ---> you specify the print command here, the example print command should work for you without
any problems
[C] ----> will be visible in the network as C
comment ---> with the following comment
writable ---> so you can write to the share [please not that you must change the premission of the share as well [for example /disk2 rwxrwxrwx , or rwx rw rw]
guest ok ---> anyone can access it
create mask = 0777, since windows programs does not know what are the file premissions under a linux formated driver, you will have problems if you don't use this.
rwxrwxrwx = 111 111 111= 7 7 7 [binary to octal]

Sincerely
Robert B
andy1974
unsure.gif wink.gif sad.gif mad.gif blink.gif

I just dont get it ...sad.gif....i was able to add the new drive to the computer.... i was able to fdisk and format also .....but its the mounting and makeing the directory on the new drive thats giving me trouble...i wanted to have a folder on the new drive for my network to use the drive for samba shareing......i wanted to be able to make a folder called /samba that i can make sub folders in the samba main folder.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2017 Invision Power Services, Inc.