LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 04-23-2007, 12:49 PM   #1
nass
Member
 
Registered: Apr 2006
Location: Athens, Greece
Distribution: slack(64|32)_v(13.37|14.0), debian6, ubuntu
Posts: 630

Rep: Reputation: 36
arghhh raid5 with 4x320GB drives and df returns 320GB for size of node!!!


hello everyone,
i am trying to set up raid5 with 4x 320GB drives at the moment.
while the process is still ongoing
i can check the raid configuration with mdadm -D /dev/md0.. that returns 'array size = 960GB'
this is normal and to be expected as n-1 = 4-1 = 3 drves x 320GB each = 960GB.

but if i df /dev/md0.. it returns 320GB..????

why does it do that?
nass
 
Old 04-23-2007, 03:20 PM   #2
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
I don't trust df. Is it just df that's the problem ?
 
Old 04-23-2007, 05:03 PM   #3
nass
Member
 
Registered: Apr 2006
Location: Athens, Greece
Distribution: slack(64|32)_v(13.37|14.0), debian6, ubuntu
Posts: 630

Original Poster
Rep: Reputation: 36
how else can i verify the result?
i thought only the Disk-Free utility returns the free disk space....
 
Old 04-23-2007, 05:15 PM   #4
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
Hmmm ... I don't really know. I think unless there is RAID-specific program that does the same thing, 'df' may be the only way to check free disk space.
 
Old 04-24-2007, 03:29 AM   #5
nass
Member
 
Registered: Apr 2006
Location: Athens, Greece
Distribution: slack(64|32)_v(13.37|14.0), debian6, ubuntu
Posts: 630

Original Poster
Rep: Reputation: 36
still i didn't leave it to chance.
i changed the drives type from the partition table with fdisk to 'linux' (code=83).
then reformatted all of them with mkreiserfs.
finally used the following /etc/raidtab file

raiddev /dev/md0
raid-level 5
nr-raid-disks 4
nr-spare-disks 0
persistent-superblock 1
parity-algorithm left-symmetric
chunk-size 128
device /dev/sdb1
raid-disk 0
device /dev/sdc1
raid-disk 1
device /dev/sdd1
raid-disk 2
device /dev/sde1
raid-disk 3

and did 'mkraid /dev/md0'...
this time around df returns the proper size (thats 4-1 drivers x 320GB = 960GB).
once done, i changed the partition table type back to 'fd' (linux raid) and
FORMATTED also /dev/md0 node, cause it wouldn't find a superblock on this node.
so mkreiserfs /dev/md0 too..
done with that too , i mounted, restarted and found that it was properly mounted...
and df always returns correct...

just a question. if i do:
Quote:
root@Stargaze:~# mdadm -E /dev/md0
mdadm: No md superblock detected on /dev/md0.
i get this response...

is that normal? i mean only the partitions making up a raid array have a superblock? or the /dev/md0 node too?
nass
 
Old 04-24-2007, 09:25 AM   #6
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
I think only partitions have a superblock.
 
  


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
3x320GB hd's in raid5 returns df = 320GB instead of 640GB nass Linux - Server 1 04-23-2007 08:37 AM
Function that returns the size of a file in bytes in C kalamaraki Programming 2 01-07-2007 11:22 AM
HW raid5 or raid1, & how many drives? hank43 Linux - Enterprise 2 12-18-2006 09:03 AM
shmget returns invalid segment size specified BobS0327 Programming 1 11-08-2006 01:49 PM
Bash script that returns the size of a file spank Linux - General 6 01-19-2006 03:24 PM


All times are GMT -5. The time now is 12:12 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration