Re: Does anyone have software RAID 1 mirroring of / set up on Sparc?
On Wed, 5 Apr 2006 12:20:17 +0100, Ashley Hooper wrote: Everything's working now, but I find those messages about UUIDs being different between the various RAID members a bit annoying - anyone know how to fix that? Hmm, that doesn't sound right. What does 'mdadm --examine partition' say for a relevant pair of component devices? Also, what's the output of 'cat /proc/mdstat'? S. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: Does anyone have software RAID 1 mirroring of / set up on Sparc?
On Tue, 4 Apr 2006 23:11:13 +0100, Ashley Hooper wrote: It is quite tricky to get right. You might find this old post (about setting up Sarge with root on RAID-1 on my Netra) helpful: http://lists.debian.org/debian-sparc/2005/07/msg00143.html I tried something along the lines of what you advised, but can you confirm that you have to create your 1st partition (in my case /boot) starting at cylinder 1? I am unable to boot the system without doing a 'boot disk0:x' (where x is the partition containing /boot). If it's going to be part of a RAID set (rather than, say, containing n ext3 filesystem) then the first partition needs to start at cylinder 1. This is because RAID uses the whole partition (and hence the bit at the start of the disk that the boot loader would normally inhabit). When trying a straight 'boot' (i.e. boot disk0) I get the error message 'The file just loaded does not appear to be executable'. Hmm, 'something along the lines of' might not be enough. ;-) SILO can be quite picky in subtle ways. Did you do the throw-away installation on a completely separate partition, and create both halves of your RAID-1 mirrors (root and /boot) before re-running SILO? Also, it's a long time since I did this, but I think 'boot' gets interpreted as something like 'boot disk0:1', which isn't what you want. You need 'boot disk0:3' (partition 3 is the 'Whole disk' partition, which always starts at cylinder 0). Also, the Silo docs say for the -t option: Stores the boot block into the same partition as the second stage loader. By default, when using a SCSI or an IDE disk, SILO writes the boot block into the master boot (the boot block of the partition starting at cylinder 0). This behaviour can be changed with the -t argument. Of course, I don't have any partition starting at cylinder 0. Well, partition 3 (Whole disk) starts at cylinder 0. Anyway, the order I did things in meant that I didn't need any command line arguments when running SILO. S. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
RE: Does anyone have software RAID 1 mirroring of / set up on Sparc?
Thanks for all your help Simon - I've updated the Openboot default boot to be partition 3 (All disk) and it works. We're so close... I did set things up slightly different to you, in that I created a separate /boot (partition 1, starting at cylinder 1, on each disk). After that I created swap and root partitions. After updating /etc/fstab for mirrored /boot swap I can successfully boot into the system and can see that both are using the mirrors. However, when it comes to mounting / from the md the boot dies - at the bottom of this email I've pasted output of the last stage of the boot process. I can confirm that: I compiled kernel with all require storage drivers, RAID support RAID1 compiled in I've set all of the RAID partitions as type 'fd'. I've created the RAID device /dev/md2 for / on /dev/sda4 /dev/sdb4 I mkfs'd /dev/md2, mounted on /mnt and copied / to it using cp -ax / /mnt I updated /mnt/etc/fstab to use /dev/md2 for / I copied the existing silo.conf entry for my working, unmirrored root drive (sda5), gave it a unique silo label and added a statement root=/dev/md2 Here's what my .config has to say about RAID CONFIG_RAID_ATTRS=y # CONFIG_BLK_DEV_3W__RAID is not set # CONFIG_SCSI_AACRAID is not set # CONFIG_MEGARAID_NEWGEN is not set # CONFIG_MEGARAID_LEGACY is not set # CONFIG_MEGARAID_SAS is not set # Multi-device support (RAID and LVM) CONFIG_MD_RAID0=m CONFIG_MD_RAID1=y CONFIG_MD_RAID10=m CONFIG_MD_RAID5=m CONFIG_MD_RAID6=m And here's the boot output as promised (after the message 'Unable to open an initial console', the system has most definitely hung up its guns!): md: Autodetecting RAID arrays. md: autorun ... md: considering sdb4 ... md: adding sdb4 ... md: sdb2 has different UUID to sdb4 md: sdb1 has different UUID to sdb4 md: adding sda4 ... md: sda2 has different UUID to sdb4 md: sda1 has different UUID to sdb4 md: created md2 md: bindsda4 md: bindsdb4 md: running: sdb4sda4 raid1: raid set md2 active with 2 out of 2 mirrors md: considering sdb2 ... md: adding sdb2 ... md: sdb1 has different UUID to sdb2 md: adding sda2 ... md: sda1 has different UUID to sdb2 md: created md1 md: bindsda2 md: bindsdb2 md: running: sdb2sda2 raid1: raid set md1 active with 2 out of 2 mirrors md: considering sdb1 ... md: adding sdb1 ... md: adding sda1 ... md: created md0 md: bindsda1 md: bindsdb1 md: running: sdb1sda1 raid1: raid set md0 active with 2 out of 2 mirrors md: ... autorun DONE. kjournald starting. Commit interval 5 seconds EXT3-fs: mounted filesystem with ordered data mode. VFS: Mounted root (ext3 filesystem) readonly. Warning: unable to open an initial console. This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify [EMAIL PROTECTED] This email has been scanned for all viruses by the FFastFill Email Security System.
RE: Does anyone have software RAID 1 mirroring of / set up on Sparc?
However, when it comes to mounting / from the md the boot dies - at the bottom of this email I've pasted output of the last stage of the boot process. Just to let you know, as I suspected, it was a udev problem. In my case it was because the new filesystem didn't contain the character special devices for console null. Fixed by: 1. booting non-mirrored root 2. mount /dev/md2 /mnt 3. cd /mnt/dev 4. mknod console c 5 1 5. mknod null c 1 3 Everything's working now, but I find those messages about UUIDs being different between the various RAID members a bit annoying - anyone know how to fix that? This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify [EMAIL PROTECTED] This email has been scanned for all viruses by the FFastFill Email Security System.
RE: Does anyone have software RAID 1 mirroring of / set up on Sparc?
Hmm, now I'm getting a kernel panic as the system prepares to REBOOT (i.e. while Linux shuts down services and unmounts filesystems in preparation for rebooting). This means that effectively every time we reboot the server we would have to use LOM to reset the chassis, which we really do not want. I've noticed that although the panic occurs when kernel tries to mount root *read-only* before restarting, the data on root gets out of sync between reboots. I can tell this because a minute or so after rebooting I see this on the console: md: md2: sync done. RAID1 conf printout: --- wd:2 rd:2 disk 0, wo:0, o:1, dev:sda4 disk 1, wo:0, o:1, dev:sdb4 Does anyone have any ideas on what might be causing this, and if there's a workaround for it? As it seems it might be related to the migration of root to md/addition of LVM, here's what my mount table looks like: /dev/md2 on / type ext3 (rw,errors=remount-ro) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) usbfs on /proc/bus/usb type usbfs (rw) tmpfs on /dev/shm type tmpfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) /dev/md0 on /boot type ext3 (rw,errors=remount-ro) /dev/mapper/volgroup-lvol0 on /var type ext3 (rw) /dev/mapper/volgroup-lvol1 on /home type ext3 (rw) tmpfs on /dev type tmpfs (rw,size=10M,mode=0755) Below is the panic output: - Will now deactivate swap. swapoff on /dev/md1 Done deactivating swap. Will now unmount local filesystems. /dev/mapper/volgroup-lvol0 umounted /dev/mapper/volgroup-lvol1 umounted Could not find /dev/.static/dev in mtab /dev/.static/dev umounted /dev/md0 umounted Done unmounting local filesystems. Shutting down LVM Volume Groups... 0 logical volume(s) in volume group volgroup now active Mounting root files \|/ \|/ ystem read-only @'/ .. \`@ .. /_| \__/ |_\ \__U_/ swapper(0): Kernel bad sw trap 5 [#1] TSTATE: 000811f09603 TPC: 00527c08 TNPC: 00527c0c Y: 000 0Not tainted TPC: U3memcpy+0x8/0x500 g0: 0003 g1: 00a4 g2: 0001 g3: f f5c g4: f8103f48a4a0 g5: f8001bf98000 g6: f8103eff8000 g7: f8103eca4 018 o0: f8103eca4538 o1: f8103ec5cc18 o2: fae0 o3: 0 000 o4: 0010 o5: sp: f8103effa831 ret_pc: 0 047a7fc RPC: cache_flusharray+0x5c/0xb4 l0: ff5c l1: f8103ec5cc00 l2: f8103eca2ec0 l3: f8103eca2 ee0 l4: l5: 0001 l6: 07290400 l7: 0 000 i0: f8103f4aa9c0 i1: f8103ecbd380 i2: f8103eca4000 i3: 0 000 i4: f8103f492c18 i5: i6: f8103effa8f1 i7: 0047a 318 I7: kmem_cache_free+0x4c/0x7c Caller[0047a318]: kmem_cache_free+0x4c/0x7c Caller[00462d74]: mempool_free+0x88/0x98 Caller[00482f00]: bio_put+0x40/0x50 Caller[0047f9c0]: end_bio_bh_io_sync+0x50/0x64 Caller[004832a0]: bio_endio+0x7c/0x8c Caller[005f2c28]: raid_end_bio_io+0x34/0xa0 Caller[005f5b20]: raid1_end_write_request+0x264/0x2d4 Caller[004832a0]: bio_endio+0x7c/0x8c Caller[0050f088]: __end_that_request_first+0x1a8/0x4f4 Caller[005b5670]: scsi_end_request+0x18/0xe0 Caller[005b5908]: scsi_io_completion+0x1d0/0x474 Caller[005c903c]: sd_rw_intr+0x2d8/0x304 Caller[005af848]: scsi_finish_command+0xbc/0xcc Caller[0050e178]: blk_done_softirq+0x78/0x9c Caller[00444b70]: __do_softirq+0x4c/0xf8 Caller[00444c58]: do_softirq+0x3c/0x50 Caller[00408894]: tl0_irq4+0x14/0x20 Caller[0040f098]: cpu_idle+0x34/0x58 Caller[0042483c]: do_unlock+0x12c/0x140 Caller[4000]: 0x4000 Instruction DUMP: 0100 8532b01f 80a0a000 93d03005 9818 80a2a000 02 600123 96120009 80a2a010 Kernel panic - not syncing: Aiee, killing interrupt handler! TSTATE: 008080f09606 TPC: 00672fcc TNPC: 00672fc0 Y: 000 0Not tainted TPC: _write_unlock_irq+0x7c/0x124 g0: g1: 00ff g2: 1000 g3: 0 197 g4: f8103ecb9a00 g5: f8001bfa g6: f8103f47 g7: 0 080 o0: f8103ecbd3cc o1: f8103ecbd400 o2: o3: 0 000 o4: f8103ee75018 o5: sp: f8103f473331 ret_pc: 0 047a618 RPC: cache_reap+0x4c/0x1d4 l0: 0001 l1: f8103f4aab28 l2: f8103ecbd3cc l3: 0 001 l4: l5: 0001 l6: l7: 3 eea i0: f8103f4aa9c0 i1: f8103ecbd380 i2: 0001 i3: 0 008 i4: i5: 00200200 i6: f8103f4733f1 i7: 00450 370 I7: run_workqueue+0xa8/0x108 0Press Stop-A (L1-A) to return to the boot prom
Re: Does anyone have software RAID 1 mirroring of / set up on Sparc?
On Tuesday 04 April 2006 12:50, Ashley Hooper wrote: I've been struggling with this for the last few days but no matter what I do I cannot get a mirrored root filesystem on my V240. Generally what happens is that SILO refuses to boot from the partition as soon as it's changed to type 'fd' (RAID autodetect). Other times it starts to boot but only gets as far as single user mode and then cannot mount root properly. Have you tried setting up a separate (normal) /boot partition? That is the general solution to problems like you describe. pgpaIcDYDPJfx.pgp Description: PGP signature
Re: Does anyone have software RAID 1 mirroring of / set up on Sparc?
Ashley Hooper a écrit : Hi all, Hello, I've been struggling with this for the last few days but no matter what I do I cannot get a mirrored root filesystem on my V240. Generally what happens is that SILO refuses to boot from the partition as soon as it's changed to type 'fd' (RAID autodetect). Other times it starts to boot but only gets as far as single user mode and then cannot mount root properly. The way I've been working is like this: 1. install Debian to /dev/sda: /dev/sda1 - 3 GB swap /dev/sda2 - 10 GB root /dev/sda4 - 20 GB /var /dev/sda5 - 15 GB /home /dev/sda3 becomes the Sparc 'all disk' partition. NB I also tried a separate /boot partition but that didn't work either. When I try to install a debian/sparc with Raid1, I use : /dev/sda1 : /boot /dev/sda2 : swap /dev/sda[4-8] for all other partitions. The first system I install is on /dev/sda2 partition without raid. It only a minimal system. I rebuild a kernel with raid1 buimtin support. After that, I build all raid1 arrays : /dev/md0 : /dev/sda1, /dev/sdb1 - /boot /dev/md1 : /dev/sda4, /dev/sdb4 - / ... I copy the system from /dev/sda2 to /dev/md0 and /dev/md1 with rsync. I lauch silo (with append=md1,/dev/sda2,/dev/sdb2), I reboot with root=/dev/md1 and I configure /dev/mdx for the swap. The first partition has to be ext3 or fd, not swap because swap writes from first block and avoid silo block. If swap begins on the cylinder 1, openprom cannot boot (ther is not MBR on sparc architecture). That's all ;-) Regards, JKB -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: Does anyone have software RAID 1 mirroring of / set up on Sparc?
On Tue, 4 Apr 2006 11:50:53 +0100, Ashley Hooper wrote: Hi all, Hi. Please don't start a new thread by replying to an existing one. I've been struggling with this for the last few days but no matter what I do I cannot get a mirrored root filesystem on my V240. Generally what happens is that SILO refuses to boot from the partition as soon as it's changed to type 'fd' (RAID autodetect). Other times it starts to boot but only gets as far as single user mode and then cannot mount root properly. It is quite tricky to get right. You might find this old post (about setting up Sarge with root on RAID-1 on my Netra) helpful: http://lists.debian.org/debian-sparc/2005/07/msg00143.html S. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
RE: Does anyone have software RAID 1 mirroring of / set up on Sparc?
Hi Simon, It is quite tricky to get right. You might find this old post (about setting up Sarge with root on RAID-1 on my Netra) helpful: http://lists.debian.org/debian-sparc/2005/07/msg00143.html I tried something along the lines of what you advised, but can you confirm that you have to create your 1st partition (in my case /boot) starting at cylinder 1? I am unable to boot the system without doing a 'boot disk0:x' (where x is the partition containing /boot). When trying a straight 'boot' (i.e. boot disk0) I get the error message 'The file just loaded does not appear to be executable'. Also, the Silo docs say for the -t option: Stores the boot block into the same partition as the second stage loader. By default, when using a SCSI or an IDE disk, SILO writes the boot block into the master boot (the boot block of the partition starting at cylinder 0). This behaviour can be changed with the -t argument. Of course, I don't have any partition starting at cylinder 0. I'd really appreciate if you could tell me how I can make Silo put something into cylinder 0 so that a normal boot will work? Cheers Ashley This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify [EMAIL PROTECTED] This email has been scanned for all viruses by the FFastFill Email Security System.