LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   help with partition formatting and reisferFS (https://www.linuxquestions.org/questions/linux-newbie-8/help-with-partition-formatting-and-reisferfs-180030/)

debloxie 05-10-2004 02:29 PM

help with partition formatting and reisferFS
 
pls i have a 40G hard disk with a 12G set aside for a cache directory

i want the this partition to be formatted with reiserFS.

i have reiserfs compiled in the kernel and have also mkreiserfs tool

this is the result of my fdisk- l

[root@linuxbox squid]# fdisk -l

Disk /dev/hdb: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hdb1 * 1 13 104391 83 Linux
/dev/hdb2 14 1160 9213277+ 83 Linux
/dev/hdb3 1161 2116 7679070 83 Linux
/dev/hdb4 2117 4865 22081342+ f Win95 Ext'd (LBA)
/dev/hdb5 2117 3072 7679038+ 83 Linux
/dev/hdb6 3073 3203 1052226 82 Linux swap
/dev/hdb7 3204 4765 12546733+ 83 Linux

the cache partition is on /dev/hda7 and this is my fstab

[root@linuxbox squid]# cat /etc/fstab
LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
LABEL=/usr /usr ext3 defaults 1 2
LABEL=/var /var ext3 defaults 1 2
/dev/hdb6 swap swap defaults 0 0
/dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0

this is my df -l command output:

[root@linuxbox squid]# df -l
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/hdb2 9068648 183700 8424288 3% /
/dev/hdb1 101089 11772 84098 13% /boot
none 253012 0 253012 0% /dev/shm
/dev/hdb5 7558368 2473352 4701068 35% /usr
/dev/hdb3 7558400 73388 7101060 2% /var
/dev/cdrom 42520 42520 0 100% /mnt/cdrom

the partition /dev/hda7 is meant for the squid cache directory to be formatted with reiserfs

i have tried using webmin interface to run the command but it gives me this:

Executing command yes | mkreiserfs /dev/hdb7 ..


<-------------mkreiserfs, 2002------------->
reiserfsprogs 3.6.4

mkreiserfs: Guessing about desired format..
mkreiserfs: Kernel 2.4.21IMQ is running.
reiserfs_create: can not create that small (0 blocks) filesystem

.. command failed!

what do u think is wrong?

Thanks

Tinkster 05-10-2004 02:35 PM

Try running it from a command-line ...

mkreiserfs /dev/hdb7


No need for webmin, this task isn't THAT hard ;)



Cheers,
Tink

debloxie 05-10-2004 03:06 PM

with all the things i have told and all the command output, u mean this is just what i need to run? and the partion formatted with reiserfs? but i am not sure whether the partiton is ready for file system creation?

debloxie 05-11-2004 02:41 AM

pls it still gave the same output:


Executing command yes | mkreiserfs -f /dev/hdb7 ..

<-------------mkreiserfs, 2002------------->
reiserfsprogs 3.6.4

mkreiserfs: Guessing about desired format..
mkreiserfs: Kernel 2.4.21IMQ is running.
reiserfs_create: can not create that small (0 blocks) filesystem

.. command failed!

i also tried to specify blocksize bit still gave the same thing:

[root@linuxbox squid]# mkreiserfs -l /cache -f /dev/hdb7 12546733

<-------------mkreiserfs, 2002------------->
reiserfsprogs 3.6.4

mkreiserfs: Guessing about desired format..
mkreiserfs: Kernel 2.4.21IMQ is running.
reiserfs_create: no enough blocks on device


pls what can i do?

Thanks

debloxie 05-11-2004 02:46 AM

also tried creating ext 3 fs and it gave this:

Executing command mkfs -t ext3 /dev/hdb7 ..

mke2fs 1.32 (09-Nov-2002)
mkfs.ext3: Device size reported to be zero. Invalid partition specified, or
partition table wasn't reread after running fdisk, due to
a modified partition being busy and in use. You may need to reboot
to re-read your partition table.


.. command failed!

is it my hard drive?

debloxie 05-11-2004 03:27 AM

trying fdisk gives:

Unable to read /dev/hdb7

and my message in /var/log gives:

ay 10 19:56:26 linuxbox kernel: hdb7: bad access: block=128, count=2
May 10 19:56:26 linuxbox kernel: end_request: I/O error, dev 03:47 (hdb), sector 128
May 10 19:56:26 linuxbox kernel: read_super_block: bread failed (dev 03:47, block 64, size 1024)
May 10 19:56:26 linuxbox kernel: hdb7: bad access: block=16, count=2
May 10 19:56:26 linuxbox kernel: end_request: I/O error, dev 03:47 (hdb), sector 16
May 10 19:56:26 linuxbox kernel: read_super_block: bread failed (dev 03:47, block 8, size 1024)
May 11 08:47:57 linuxbox kernel: hdb: drive_cmd: status=0x51 { DriveReady SeekComplete Error }
May 11 08:47:57 linuxbox kernel: hdb: drive_cmd: error=0x04 { DriveStatusError }
May 11 08:47:57 linuxbox kernel: hdb: drive_cmd: status=0x51 { DriveReady SeekComplete Error }
May 11 08:47:57 linuxbox kernel: hdb: drive_cmd: error=0x04 { DriveStatusError }

what dies this mean?

whansard 05-11-2004 04:08 AM

for a while you were saying it was hda7 then you were trying to format hdb7 which is it?

sometimes you get those last errors when the drive is running dma and not working right.
hdparm -d0 /dev/hdb will turn that off.

debloxie 05-11-2004 05:45 AM

tried that but still the same thing.

Executing command yes | mkreiserfs -f /dev/hdb7 ..

<-------------mkreiserfs, 2002------------->
reiserfsprogs 3.6.4

mkreiserfs: Guessing about desired format..
mkreiserfs: Kernel 2.4.21IMQ is running.
reiserfs_create: can not create that small (0 blocks) filesystem

.. command failed!

do u think the hard disk is the one with the problem or maybe i shud try adding another hard disk to this and make a partition /cache on it?

do u think this will work, do i have to recompile the kernel if i add a new hard disk?

what shud i do?

thanks

debloxie 05-11-2004 05:47 AM

i have also tried ext3 and just now JFS to c what it cud give, it gave me:

Executing command mkfs -t jfs -q /dev/hdb7 ..

mkfs.jfs version 1.0.17, 02-Apr-2002
Device size reported to be zero. Invalid partition specified, or
partition table wasn't reread after running fsck, fdisk, etc.
You may need to reboot to re-read your partition table.

.. command failed!

why are all filesystems commands giving an error? is it the location of the partiton (hdb7) or the blocks or sectors?

whansard 05-11-2004 06:27 AM

is squid currently using the partition?
there may be bad sectors on that partition at the beginning?
tink gave you the right command.

debloxie 05-11-2004 08:33 AM

no squid has not started using the partition. i think so too that there are bad sectors on the disk. so what do u think i use another hard disk? that shud work i think? when adding another hard disk, do i need to recompile the kernel? or does kudzu or the kernel detect the hard disk automatically? pls advice.

Thanks for ur help men

whansard 05-11-2004 10:24 AM

no recompile, just hook up and use.
you should run badblocks on your entire drive to see if bad things are happening elsewhere.
another option is deleting the partition and making the starting sector in a different place. such as delting hdb7 and making another partition with a starting cylinder of 3300, and try to format it then. use a -c to check for bad blocks. you can probably get a partition set up somehow that doesn't use the bad area.


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