Re: [gentoo-user] Re: Checking sanity of system...

2010-04-04 Thread meino . cramer
Nikos Chantziaras  [10-04-04 08:28]:
> On 04/04/2010 08:18 AM, meino.cra...@gmx.de wrote:
> >
> >Hi,
> >
> >this is no security issue in sense of attacks...it is related
> >to the consistency of the system.
> >
> >Simple question (and may be complicate to answer... ;) )
> >
> >How can I check, that my Gentoo system is uptodate
> 
> emerge --sync && emerge -uDN world
> 
> 
> >consistent and sane?
> 
> Define "consistent" and "sane".  Those words don't say anything, 
> really.
> 

Ok...

Consistency: Following each logical branch of each logical tree of control 
relationship,
which is for example but not only the tree of dependancies, will end in a
leave. These are the control paths.

Sane: Following each logical branch of each logical tree of data
relationships. which is for example but not only the interaction of scripts 
under
/etc, will end in a leave. These are the data paths.

HTH

Best regards,
mcc

-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




Re: [gentoo-user] Checking sanity of system...

2010-04-04 Thread meino . cramer
Dale  [10-04-04 08:20]:
> meino.cra...@gmx.de wrote:
> >Hi,
> >
> >this is no security issue in sense of attacks...it is related
> >to the consistency of the system.
> >
> >Simple question (and may be complicate to answer... ;) )
> >
> >How can I check, that my Gentoo system is uptodate, consistent
> >and sane?
> >
> >Best regards,
> >mcc
> >
> >
> >   
> 
> I think this is what you want.  man glsa-check  I don't use it so you 
> will have to read or wait until someone who uses it comes along.  No 
> real clue how it works.
> 
> I hope that helps and is what you are looking for.
> 
> Dale
> 
> :-)  :-)
> 

Hi Dale,

As far as I can understand the man-page, glsa-check is a tool to check
security settings in the system: _G_entoo _L_inux _S_ecurity
_A_visory.
I didnt know of this tool before so it is a goog hint anyway, but for
the moment I want only check, whether the system is not cleanly
setup/installed/updated in the sense of "it is working well" ;)

Best regards,
mcc

-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




Re: [gentoo-user] Re: Checking sanity of system...

2010-04-04 Thread meino . cramer
Dale  [10-04-04 08:36]:
> Nikos Chantziaras wrote:
> >On 04/04/2010 08:18 AM, meino.cra...@gmx.de wrote:
> >>
> >>Hi,
> >>
> >>this is no security issue in sense of attacks...it is related
> >>to the consistency of the system.
> >>
> >>Simple question (and may be complicate to answer... ;) )
> >>
> >>How can I check, that my Gentoo system is uptodate
> >
> >emerge --sync && emerge -uDN world
> >
> >
> >>consistent and sane?
> >
> >Define "consistent" and "sane".  Those words don't say anything, 
> >really.
> >
> >
> >
> 
> You may also want to run revdep-rebuild as well.  If you are talking 
> about your packages being "sane".  That should catch anything that has 
> broken links or something else that leads to a package needing to be 
> recompiled.
> 
> Dale
> 
> :-)  :-)
> 

Hi Dale,

revdep-rebuild is currently running! :)

This was the only tool I knew before posting my question here :)

:)

Best regards,
mcc


-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




[gentoo-user] Re: Checking sanity of system...

2010-04-04 Thread Nikos Chantziaras

On 04/04/2010 10:07 AM, meino.cra...@gmx.de wrote:

Nikos Chantziaras  [10-04-04 08:28]:

On 04/04/2010 08:18 AM, meino.cra...@gmx.de wrote:


Hi,

this is no security issue in sense of attacks...it is related
to the consistency of the system.

Simple question (and may be complicate to answer... ;) )

How can I check, that my Gentoo system is uptodate


emerge --sync&&  emerge -uDN world



consistent and sane?


Define "consistent" and "sane".  Those words don't say anything,
really.



Ok...

Consistency: Following each logical branch of each logical tree of control 
relationship,
which is for example but not only the tree of dependancies, will end in a
leave. These are the control paths.

Sane: Following each logical branch of each logical tree of data
relationships. which is for example but not only the interaction of scripts 
under
/etc, will end in a leave. These are the data paths.


These are very abstract things you speak of.  But I guess it boils down 
to "are there bugs in my system."


Yes, there are.  All software has bugs.  There is a tool to check 
whether there are bugs: you.  You use the software and check whether it 
works correctly or not.


For anything more specific, you also need to be more specific with your 
questions. :)





Re: [gentoo-user] Re: Checking sanity of system...

2010-04-04 Thread Dale

meino.cra...@gmx.de wrote:

Dale  [10-04-04 08:36]:
   

Nikos Chantziaras wrote:
 

On 04/04/2010 08:18 AM, meino.cra...@gmx.de wrote:
   

Hi,

this is no security issue in sense of attacks...it is related
to the consistency of the system.

Simple question (and may be complicate to answer... ;) )

How can I check, that my Gentoo system is uptodate
 

emerge --sync&&  emerge -uDN world


   

consistent and sane?
 

Define "consistent" and "sane".  Those words don't say anything,
really.



   

You may also want to run revdep-rebuild as well.  If you are talking
about your packages being "sane".  That should catch anything that has
broken links or something else that leads to a package needing to be
recompiled.

Dale

:-)  :-)

 

Hi Dale,

revdep-rebuild is currently running! :)

This was the only tool I knew before posting my question here :)

:)

Best regards,
mcc

   


When I do my updates, I always do the following:

eix-sync   # This does my emerge --sync for me and updates eix since I 
use it sometimes for the FAST searches


emerge -uvDNa world   # My system is set up so that world includes 
system so this catches everything including deep dependencies (D) and 
changes of USE flags (N).


I then check USE flags and anything else that may be odd.  If I need to 
change something, I answer NO and repeat until I get it like it should 
be.  After emerge finishes:


emerge -p --depclean  # I run that about once a month or if I know 
something is unneeded and should be removed.  If it looks sane, I rerun 
without the -p.  You could use -a I guess.


revdep-rebuild -i  # This makes sure nothing is broken and I run it each 
time after the emerge world whether --depclean is ran or not.  It 
sometimes finds something broke and fixes it so I figure it is safer to 
run it and it do nothing than to not run it and something be broken.


One more optional thing to run, python-updater.  If I see python being 
updated, I run that too.  Note:  Python 3 should be popping its head up 
if it hasn't already.  If it does, do NOT switch the system to it.  A 
lot of packages do not work with it yet.  If you switch to it, you can 
keep the pieces if it breaks.  Sane thoughts did not prevail on -dev so 
you either have to mask it locally or it will be there basically doing 
nothing.  Don't ask me why they did it.  I was against the idea myself. 
< shrugs >


That's how I do it and my little rig runs pretty good.  I do have 
hiccups on occasion but everyone does eventually.


Dale

:-)  :-)



Re: [gentoo-user] Disk or filesystem issue?

2010-04-04 Thread Mick
On Sunday 04 April 2010 01:52:17 Adam wrote:
> > Probably neither.  Can you Ctrl+F12 to see what the logs are
> > saying?  I've been getting kernel Oops! on shutdown on one
> > machine of mine with the 2.6.31-gentoo-r10 kernel.  Might be
> > similar
> 
> Ok, i found this, which is mentioning fglrx, and the problem may have
> started when i changed driver versions.
> 
> So is it possible for an X driver to cause filesystem issues? I would
> have assumed not.
> 
> 
> 
> Apr  4 10:38:08 sphinx shutdown[5768]: shutting down for system reboot
> Apr  4 10:38:09 sphinx init: Switching to runlevel: 6
> Apr  4 10:38:09 sphinx gnome-session[5585]: WARNING: Detected that
> screensaver has left the bus
> Apr  4 10:38:09 sphinx gnome-keyring-daemon[5614]: dbus failure
> unregistering from session: Connection is closed
> Apr  4 10:38:09 sphinx su[5753]: pam_unix(su:session): session closed
> for user root
> Apr  4 10:38:09 sphinx kernel: uhci_hcd :00:1d.1: release dev 2
> ep81-INT, period 8, phase 4, 93 us
> Apr  4 10:38:09 sphinx kernel: uhci_hcd :00:1a.0: release dev 4
> ep81-INT, period 8, phase 4, 14 us
> Apr  4 10:38:09 sphinx kernel: __ratelimit: 20 callbacks suppressed
> Apr  4 10:38:09 sphinx kernel: BUG: using smp_processor_id() in
> preemptible [] code: X/5275
> Apr  4 10:38:09 sphinx kernel: caller is KAS_GetExecutionLevel+0xd/0x120
> [fglrx]
> Apr  4 10:38:09 sphinx kernel: Pid: 5275, comm: X Tainted: P
> 2.6.31-gentoo-r6 #4
> Apr  4 10:38:09 sphinx kernel: Call Trace:
> Apr  4 10:38:09 sphinx kernel: [] ?
> debug_smp_processor_id+0xd9/0xe0
> Apr  4 10:38:09 sphinx kernel: [] ?
> KAS_GetExecutionLevel+0xd/0x120 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> MCIL_GetExecutionLevel+0x39/0x80 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> CallbackQueueAccess+0x2b/0x2a0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> UnRegisterIRQClient_Worker+0x0/0xe0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> MCIL_bMiniportCapEnabled+0x82/0xa0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> UnRegisterIRQClient+0x83/0xe0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> IRQMGR_IRQSourceSupported+0x7e/0xa0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> IRQMGR_Access+0x131/0x190 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> fireglAsyncioUnregisterIntMsgHandlers+0x2c3/0x3c0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> asyncIONotifyMsg+0x234/0x3e0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> firegl_asyncio_write+0x189/0x250 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ?
> ip_firegl_write+0x58/0xa0 [fglrx]
> Apr  4 10:38:09 sphinx kernel: [] ? vfs_write+0xcb/0x180
> Apr  4 10:38:09 sphinx kernel: [] ? sys_write+0x53/0xa0
> Apr  4 10:38:09 sphinx kernel: [] ?
> system_call_fastpath+0x16/0x1b
> Apr  4 10:38:09 sphinx kernel: BUG: using smp_processor_id() in
> preemptible [] code: X/5275
> Apr  4 10:38:09 sphinx kernel: caller is
> KCL_SPINLOCK_STATIC_Grab+0x25/0x110 [fglrx]
> Apr  4 10:38:09 sphinx kernel: Pid: 5275, comm: X Tainted: P
> 2.6.31-gentoo-r6 #4
> Apr  4 10:38:09 sphinx kernel: Call Trace:
> Apr  4 10:38:09 sphinx kernel: [] ?
> debug_smp_processor_id+0xd9/0xe0

It could be that this kernel does not play well with fglrx?  I would unmask 
the next kernel up the tree and try that out.  This particular kernel version 
you are running had a few bugs hanging around, which may affect your problem.

PS.  My machine that keeps crashing on shutdown doesn't always crash at 
exactly the same point - but it is well after X has been stopped and 
invariably after the fs has been unmounted.

PPS.  Clutching at straws, but just for testing purposes you may want to boot 
with no X, just on a console and try shuting down from there?

-- 
Regards,
Mick


signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] Checking sanity of system...

2010-04-04 Thread Norman Rieß
Am 04.04.2010 07:18, schrieb meino.cra...@gmx.de:
> Hi,
>
> this is no security issue in sense of attacks...it is related
> to the consistency of the system.
>
> Simple question (and may be complicate to answer... ;) )
>
> How can I check, that my Gentoo system is uptodate, consistent 
> and sane?
>
> Best regards,
> mcc
>
>
>   
Hi,

Every Update:
emerge --sync && emerge -uDN world
--> Read the Packagemessages for Instructions.
etc-update# Merge new Configfiles
revdep-rebuild# Identify broken libraries

>From time to time:
emerge --deplcean (-p) && revdep-rebuild# Delete old packages and
sort out the resulting broken packages
eclean distfiles# Delete the old source-packages in your distfile repo.

Regards,
Norman




Re: [gentoo-user] How does grub assemble a RAID1 for / ??

2010-04-04 Thread Xavier Parizet
Try appending md=3,/dev/sdb3,/dev/sdc3 to the kernel command line
parameters.

On 04/04/2010 01:45 AM, Albert Hopkins wrote:
> On Sat, 2010-04-03 at 16:07 -0700, Mark Knecht wrote:
>> The install is complete but it won't boot. grub finds the kernel
>> and starts booting but then I get the typical VFS file sync error as
>> the kernel starts looking for the install on /dev/md3. What I'm not
>> understanding is how does the boot process get the information
>> required to assemble the RAID device. 
> 
> GRUB does not assemble raid.  That's why it only works with RAID1.
> 
> By your own account, GRUB has succeeded, therefore GRUB is not the
> problem.
> 
> The problem is the kernel
> 
> The kernel assembles RAID by looking for partitions of with the Linux
> RAID partition type, finding out what kind of RAID they are, and
> assembling them (according to their RAID volume UUID).
> 
> You apparently only have one RAID volume.  It's probably being assigned
> to /dev/md0, yet you are passing root=/dev/md3.. not sure why you are
> doing that.

-- 
  Xavier Parizet
YaGB :   http://gentooist.com
GPG  :C7DC B10E FC21 63BE
B453 D239 F6E6 DF65 1569 91BF



signature.asc
Description: OpenPGP digital signature


Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sat, Apr 3, 2010 at 7:38 PM, Kerin Millar  wrote:
> On 04/04/2010 02:01, Mark Knecht wrote:
>>
>> Tried changing root=/dev/md0. No change.
>>
>> The actual failure message is the fairly standard
>>
>> VFS - Unable to mount root fs on unknown-block(9,0)
>
> [snip]
>
>> CONFIG_MD_RAID1=y
>
> That's all that needs to be enabled within the RAID section of the kernel.
> However, all the other options that would normally be required to boot must
> also be compiled in statically for things to work as expected (ATA/SCSI
> controller driver, filesystem of choice, CONFIG_BLK_DEV_SD and so forth). It
> seems that you may have overlooked something. However, it's impossible to
> determine whether that's the case based on the information presented thus
> far.
>
> I would suggest that you double-check your .config in full, or present it
> here for review, along with the output of lspci -nn.
>
> Cheers,
>
> --Kerin

Hi Kerin,
   Happy for any help I can get.

   Instead of the whole .config file here's a diff. Remember that the
machine already boots non-RAID from /dev/sda and I'm trying to build
my first RAID boot on /dev/sdb & sdc.

   First, here's the RAID I would like to boot from:

keeper ~ # mdadm -A /dev/md3 /dev/sdb3 /dev/sdc3
mdadm: /dev/md3 has been started with 2 drives.
keeper ~ # mdadm --detail /dev/md3
/dev/md3:
Version : 1.01
  Creation Time : Sat Apr  3 11:43:39 2010
 Raid Level : raid1
 Array Size : 52436092 (50.01 GiB 53.69 GB)
  Used Dev Size : 52436092 (50.01 GiB 53.69 GB)
   Raid Devices : 2
  Total Devices : 2
Persistence : Superblock is persistent

Update Time : Sun Apr  4 06:40:54 2010
  State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

   Name : keeper:3  (local to host keeper)
   UUID : 6dcf5ddb:c4a2d5ea:ba59df10:f5473502
 Events : 3703

Number   Major   Minor   RaidDevice State
   0   8   190  active sync   /dev/sdb3
   1   8   351  active sync   /dev/sdc3
keeper ~ # cat /proc/mdstat
Personalities : [raid1]
md3 : active raid1 sdb3[0] sdc3[1]
  52436092 blocks super 1.1 [2/2] [UU]

unused devices: 
keeper ~ #

Here's the diff of the running kernel without RAID and the kernel I
created while in the install chroot on the RAID device:

 keeper ~ # diff /usr/src/linux/.config /mnt/gentoo/usr/src/linux/.config
4c4
< # Mon Mar 29 01:02:31 2010
---
> # Sun Apr  4 06:28:53 2010
893,912c893,906
< CONFIG_MD_LINEAR=m
< CONFIG_MD_RAID0=m
< CONFIG_MD_RAID1=m
< CONFIG_MD_RAID10=m
< CONFIG_MD_RAID456=m
< # CONFIG_MULTICORE_RAID456 is not set
< CONFIG_MD_RAID6_PQ=m
< # CONFIG_ASYNC_RAID6_TEST is not set
< CONFIG_MD_MULTIPATH=m
< CONFIG_MD_FAULTY=m
< CONFIG_BLK_DEV_DM=m
< CONFIG_DM_DEBUG=y
< CONFIG_DM_CRYPT=m
< CONFIG_DM_SNAPSHOT=m
< CONFIG_DM_MIRROR=m
< # CONFIG_DM_LOG_USERSPACE is not set
< CONFIG_DM_ZERO=m
< CONFIG_DM_MULTIPATH=m
< # CONFIG_DM_MULTIPATH_QL is not set
< # CONFIG_DM_MULTIPATH_ST is not set
---
> # CONFIG_MD_LINEAR is not set
> CONFIG_MD_RAID0=y
> CONFIG_MD_RAID1=y
> # CONFIG_MD_RAID10 is not set
> # CONFIG_MD_RAID456 is not set
> # CONFIG_MD_MULTIPATH is not set
> # CONFIG_MD_FAULTY is not set
> CONFIG_BLK_DEV_DM=y
> # CONFIG_DM_DEBUG is not set
> # CONFIG_DM_CRYPT is not set
> # CONFIG_DM_SNAPSHOT is not set
> # CONFIG_DM_MIRROR is not set
> # CONFIG_DM_ZERO is not set
> # CONFIG_DM_MULTIPATH is not set
914,915c908,909
< CONFIG_DM_UEVENT=y
< CONFIG_BLK_DEV_DM_BBR=m
---
> # CONFIG_DM_UEVENT is not set
> # CONFIG_BLK_DEV_DM_BBR is not set
2293,2298d2286
< CONFIG_XOR_BLOCKS=m
< CONFIG_ASYNC_CORE=m
< CONFIG_ASYNC_MEMCPY=m
< CONFIG_ASYNC_XOR=m
< CONFIG_ASYNC_PQ=m
< CONFIG_ASYNC_RAID6_RECOV=m
keeper ~ #

   One additional thing I thought of last night was some message that
came up when I first built the RAID about the partitions having
metadata and to be sure that the bootloader understands metadata. In
the cool light of morning that seems fairly important. I am using
grub-static on this machine. I assumed this would be OK but possibly
it isn't?

   If rebuilding the RAID from scratch is important, or just makes
things more straight forward, then don't hesitate to suggest it and
I'll document the build step by step. This install isn't important.
I'm just doing it to learn how to do RAID and most importantly to test
the disk drives. I purchased other disk drives that aren't working
with RAID at all so I wanted to test these a bit before I did anything
real. The final install with be a 3 disk RAID1 but the 3rd drive
hasn't arrived yet so none of this is critically important.

   Thanks!

Cheers,
Mark



Re: [gentoo-user] How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 2:57 AM, Xavier Parizet  wrote:
> Try appending md=3,/dev/sdb3,/dev/sdc3 to the kernel command line
> parameters.
>

Thanks. Tried that one last night but no luck, although it does change
the message to Unknown-block(9,3) from Unknown-block(9,0).

Cheers,
Mark



[gentoo-user] Problems with booting from SD card on EEE 1201H

2010-04-04 Thread Jonas de Buhr
Hello Everyone!

I am trying to install gentoo on my eee1201h and used this howto:
http://www.gentoo.org/doc/en/liveusb.xml
to setup a bootable SD card.

The system boots but depscan fail with 
"line 128: /bin/chmod: Input/Output Error"
"line 139: Bus Error"

and a lot more. 
Almost every command i issue in the shell fails with Input/Output
error (even ls).

Any ideas how I can get this to work?

Thanks,
jdb



[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 04/04/2010 15:20, Mark Knecht wrote:

On Sat, Apr 3, 2010 at 7:38 PM, Kerin Millar  wrote:

On 04/04/2010 02:01, Mark Knecht wrote:


Tried changing root=/dev/md0. No change.

The actual failure message is the fairly standard

VFS - Unable to mount root fs on unknown-block(9,0)


[snip]


CONFIG_MD_RAID1=y


That's all that needs to be enabled within the RAID section of the kernel.
However, all the other options that would normally be required to boot must
also be compiled in statically for things to work as expected (ATA/SCSI
controller driver, filesystem of choice, CONFIG_BLK_DEV_SD and so forth). It
seems that you may have overlooked something. However, it's impossible to
determine whether that's the case based on the information presented thus
far.

I would suggest that you double-check your .config in full, or present it
here for review, along with the output of lspci -nn.

Cheers,

--Kerin


Hi Kerin,
Happy for any help I can get.

Instead of the whole .config file here's a diff. Remember that the
machine already boots non-RAID from /dev/sda and I'm trying to build
my first RAID boot on /dev/sdb&  sdc.



No, really, the whole thing needs to be seen, along with the lspci data. 
It's very likely that this thread can be drawn to a close if you provide 
exactly what's being asked for :)



One additional thing I thought of last night was some message that
came up when I first built the RAID about the partitions having
metadata and to be sure that the bootloader understands metadata. In


The bootloader does not enter into this. If the kernel is being loaded - 
which, by your own admission it is - the bootloader has done its job. 
What happens thereafter is entirely the responsibility of the kernel.


Essentially, the subject of this thread is a misnomer and the issue lies 
with your kernel.


As for the warning regarding metadata, it's applicable to legacy 
bootloaders which may not be able to fathom the presence of the md 
superblock data at the beginning of a block device that happens to be a 
member of a raid1 volume. As far as grub is concerned, this is a 
non-issue. Even if it were an issue, you wouldn't even get as far as 
being able to load the kernel in the first instance. Indeed, the 
bootloader itself would likely fail to initialise properly.


>If rebuilding the RAID from scratch is important, or just makes
> things more straight forward, then don't hesitate to suggest it and
> I'll document the build step by step. This install isn't important.

On the other hand, if you don't get to the point of understanding why 
the kernel isn't configured so as to be able to assemble the array on 
this occasion, a re-install isn't going to change that. Moreover, you 
won't be able to fix any such problem that may occur again unaided.


Cheers,

--Kerin




Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 10:32 AM, Kerin Millar  wrote:
> On 04/04/2010 15:20, Mark Knecht wrote:
>>
>> On Sat, Apr 3, 2010 at 7:38 PM, Kerin Millar  wrote:
>>>
>>> On 04/04/2010 02:01, Mark Knecht wrote:

 Tried changing root=/dev/md0. No change.

 The actual failure message is the fairly standard

 VFS - Unable to mount root fs on unknown-block(9,0)
>>>
>>> [snip]
>>>
 CONFIG_MD_RAID1=y
>>>
>>> That's all that needs to be enabled within the RAID section of the
>>> kernel.
>>> However, all the other options that would normally be required to boot
>>> must
>>> also be compiled in statically for things to work as expected (ATA/SCSI
>>> controller driver, filesystem of choice, CONFIG_BLK_DEV_SD and so forth).
>>> It
>>> seems that you may have overlooked something. However, it's impossible to
>>> determine whether that's the case based on the information presented thus
>>> far.
>>>
>>> I would suggest that you double-check your .config in full, or present it
>>> here for review, along with the output of lspci -nn.
>>>
>>> Cheers,
>>>
>>> --Kerin
>>
>> Hi Kerin,
>>    Happy for any help I can get.
>>
>>    Instead of the whole .config file here's a diff. Remember that the
>> machine already boots non-RAID from /dev/sda and I'm trying to build
>> my first RAID boot on /dev/sdb&  sdc.
>>
>
> No, really, the whole thing needs to be seen, along with the lspci data.
> It's very likely that this thread can be drawn to a close if you provide
> exactly what's being asked for :)
>
>>    One additional thing I thought of last night was some message that
>> came up when I first built the RAID about the partitions having
>> metadata and to be sure that the bootloader understands metadata. In
>
> The bootloader does not enter into this. If the kernel is being loaded -
> which, by your own admission it is - the bootloader has done its job. What
> happens thereafter is entirely the responsibility of the kernel.
>
> Essentially, the subject of this thread is a misnomer and the issue lies
> with your kernel.
>
> As for the warning regarding metadata, it's applicable to legacy bootloaders
> which may not be able to fathom the presence of the md superblock data at
> the beginning of a block device that happens to be a member of a raid1
> volume. As far as grub is concerned, this is a non-issue. Even if it were an
> issue, you wouldn't even get as far as being able to load the kernel in the
> first instance. Indeed, the bootloader itself would likely fail to
> initialise properly.
>
>>    If rebuilding the RAID from scratch is important, or just makes
>> things more straight forward, then don't hesitate to suggest it and
>> I'll document the build step by step. This install isn't important.
>
> On the other hand, if you don't get to the point of understanding why the
> kernel isn't configured so as to be able to assemble the array on this
> occasion, a re-install isn't going to change that. Moreover, you won't be
> able to fix any such problem that may occur again unaided.
>
> Cheers,
>
> --Kerin

No problem supplying it. I did the rebuild this morning but forced
metadata to Type 1.0. No change as you suggested there wouldn't be.

OK, here's:

1) lspci to read & lspci -k to see drivers both from the non-RAID kernel
2) The RAID kernel config
3) At the very end a diff between the kernel config in this email and
the running one without RAID. (I.e. - the changes I made to attempt to
mount / which is on RAID.)

Note that the Marvell SATA controller is for two external eSATA ports
that have nothing attached at this time. It's the Intel controller
that's in play here.

Thanks,
Mark

keeper ~ # lspci
00:00.0 Host bridge: Intel Corporation X58 I/O Hub to ESI Port (rev 13)
00:01.0 PCI bridge: Intel Corporation 5520/5500/X58 I/O Hub PCI
Express Root Port 1 (rev 13)
00:03.0 PCI bridge: Intel Corporation 5520/5500/X58 I/O Hub PCI
Express Root Port 3 (rev 13)
00:07.0 PCI bridge: Intel Corporation 5520/5500/X58 I/O Hub PCI
Express Root Port 7 (rev 13)
00:10.0 PIC: Intel Corporation 5520/5500/X58 Physical and Link Layer
Registers Port 0 (rev 13)
00:10.1 PIC: Intel Corporation 5520/5500/X58 Routing and Protocol
Layer Registers Port 0 (rev 13)
00:14.0 PIC: Intel Corporation 5520/5500/X58 I/O Hub System Management
Registers (rev 13)
00:14.1 PIC: Intel Corporation 5520/5500/X58 I/O Hub GPIO and Scratch
Pad Registers (rev 13)
00:14.2 PIC: Intel Corporation 5520/5500/X58 I/O Hub Control Status
and RAS Registers (rev 13)
00:14.3 PIC: Intel Corporation 5520/5500/X58 I/O Hub Throttle Registers (rev 13)
00:19.0 Ethernet controller: Intel Corporation 82567LM-2 Gigabit
Network Connection
00:1a.0 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB
UHCI Controller #4
00:1a.1 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB
UHCI Controller #5
00:1a.2 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB
UHCI Controller #6
00:1a.7 USB Controller: Intel Corporation 82801JI (ICH10 Family) USB2
EHCI Controller

[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 04/04/2010 18:50, Mark Knecht wrote:

[snip]


No problem supplying it. I did the rebuild this morning but forced
metadata to Type 1.0. No change as you suggested there wouldn't be.

OK, here's:

1) lspci to read&  lspci -k to see drivers both from the non-RAID kernel
2) The RAID kernel config
3) At the very end a diff between the kernel config in this email and
the running one without RAID. (I.e. - the changes I made to attempt to
mount / which is on RAID.)

Note that the Marvell SATA controller is for two external eSATA ports
that have nothing attached at this time. It's the Intel controller
that's in play here.

Thanks,
Mark


[snip lspci data]

OK.

[snip kconfig data]

Something isn't right here. This .config appears to be severely stunted. 
It's missing lots of options that should be defined (whether active or 
not). Indeed, a typical .config might easily exceed 2000 lines. It's 
also missing the comment at the top which describes the kernel version 
in use.


Is this really the entire .config file that is currently residing within 
/mnt/gentoo/usr/src/linux, having mounted the root filesystem and that 
was used to build the kernel you're attempting to boot with? If so, it's 
broken and you should just delete it entirely and start anew with make 
menuconfig. If not, then please present the file in full (no diffs, no 
obfuscation please).


Aside from all of that, notable options that are going to be required to 
boot in your case are:


CONFIG_MD_RAID1
CONFIG_SATA_AHCI
CONFIG_BLK_DEV_SD
CONFIG_BLK_DEV_SR
CONFIG_MSDOS_PARTITION (normally implicit but worth mentioning)

That, and the option corresponding with whichever filesystem you use. 
Also, make sure CONFIG_SYSFS_DEPRECATED_V2 is off or else udev will 
balk. You may use the forward slash key to search for option names in 
make menuconfig (never edit .config directly). All needed options should 
be enabled as <*>.


Also, if you're not experienced with kernel configuration and need a 
skeleton .config with which to begin, I would suggest you take a look at 
http://kernel-seeds.org.


Cheers,

--Kerin




[gentoo-user] alsa-update not in sync with kernel version

2010-04-04 Thread meino . cramer

Hi,

I am running a vanilla kernel (linux-2.6.32.11), This kernel uses
alsa-1.0.21.

When doing the eix-sync-thingy, emerge always suggests to update
to alsa-1.0.22.

Is there a way that emerge/eix or whatever relizes the version of
alsa which the kernel is runnig and only suggests updates which are
in sync which such version?

Best regards,
mcc

-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




Re: [gentoo-user] Checking sanity of system...

2010-04-04 Thread u.sch...@bluewin.ch
>Von: nor...@smash-net.org
>Datum: 04.04.2010 11:37
>An: 
>Betreff: Re: [gentoo-user] 
Checking sanity of system...
>
>Am 04.04.2010 07:18, schrieb meino.cra...@gmx.de:
>> Hi,
>>
>> this is no security 
issue in sense of attacks...it is related
>> to the consistency of the system.
>>
>> Simple question (and may be 
complicate to answer... ;) )
>>
>> How can I check, that my Gentoo system is uptodate, consistent 
>> and sane?
>>
>> 
Best regards,
>> mcc
>>
>>
>>   
>Hi,
>
>Every Update:
>emerge --sync && emerge -uDN world
>--> Read the 
Packagemessages for Instructions.
>etc-update# Merge new Configfiles
>revdep-rebuild# Identify broken libraries

>
>From time to time:
>emerge --deplcean (-p) && revdep-rebuild# Delete old packages and
>sort out the resulting 
broken packages
>eclean distfiles# Delete the old source-packages in your distfile repo.
>
>Regards,
>Norman
>
>
>


and aditionally from time to time:

eix -u
(packages  which  have  at least one slotted version installed which is not 
the best version within that slot)

and 

eix-test-obsolete -d
(display missing packages or packages with obsolete 
entries in /etc/portage/package.* )

Check for viruses, lookout for SMART data, and filesystem inconsistencies, 
check 
temperatures, check log files, listen to fans... there are many levels where a 
system could fail.

Urs





[gentoo-user] Moving the system from one disk to another

2010-04-04 Thread meino . cramer

Hi,

I have to move my whole system from one disk to another
bigger one.

I think of doing as follows:
Boot a system via CD/DVD (knoppix for example).
Mount small disk read-only 
Mount bigger disk read-write

cd into mountpoint of the first one
cp -a . ../

Seems to me slow but correct? Or?

(I have to set the bootable flag of the correct partion
additionally...)

I dont want to have a booting system afterwards, which "runs" for --
say -- three month and suddenly hit a obscure bug due to my
copy-commands, which only did it to 99.87% correct... ;)

I would like to preserve as much as possible of the file/directoy
times ,,,

Or does a mystical command with s-tar a better job faster? 

Thank you very much in adance for any help!

Best regards,
mcc

-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 04/04/2010 19:43, Mark Knecht wrote:

[snip]


Aside from all of that, notable options that are going to be required to
boot in your case are:

CONFIG_MD_RAID1
CONFIG_SATA_AHCI
CONFIG_BLK_DEV_SD
CONFIG_BLK_DEV_SR
CONFIG_MSDOS_PARTITION (normally implicit but worth mentioning)

That, and the option corresponding with whichever filesystem you use. Also,
make sure CONFIG_SYSFS_DEPRECATED_V2 is off or else udev will balk. You may
use the forward slash key to search for option names in make menuconfig
(never edit .config directly). All needed options should be enabled as<*>.

Also, if you're not experienced with kernel configuration and need a
skeleton .config with which to begin, I would suggest you take a look at
http://kernel-seeds.org.

Cheers,

--Kerin


Sorry. I was on a Windows box and it looks like putty cut it off.
Booted into Linux and this looks more correct. (2424 lines in vi on
that machine and 2424 lines in late on this machine so I think it's
all there...)

I looked at your suggestions above and they are all set to =y.
CONFIG_SYSFS_DEPRECATED_V2 is 'not set'.

- Mark

#
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.33-gentoo
# Sun Apr  4 09:56:49 2010
#


[snip long config]

Ah, that looks better. Not that I've pored over every line, but at first 
glance everything seems to be in order. There are no obvious gotchas 
that I can see, so I'm somewhat puzzled.


Here are a few random things that spring to mind though ...

I would suggest switching off CONFIG_IDE. It may contend for control of 
your hardware with the AHCI driver, assuming that emulation/comptability 
mode is enabled in the BIOS.


The device nodes may be unavailable at the time that they are needed, 
for some strange reason. If you mount the root filesystem from a livecd 
(with no bind mounts), try creating static nodes in dev/:


  mknod /dev/md0 b 9 0
  mknod /dev/md1 b 9 1
  mknod /dev/md2 b 9 2
  mknod /dev/md3 b 9 3

Note that the preferred minor of your array can be determined by 
examining any component partition. For instance, "mdadm -E /dev/sdb3".


Avoid manual specification of the RAID parameters. The kernel should be 
perfectly able to assemble the array by examining the superblocks of 
partitions of type "FD".


Does it work if you specify "root=/dev/sdb3" or "root=/dev/sdc3"? With 
raid1, it's possible to mount just the component partition (although it 
will later result in a resync). The point is, it would at least confirm 
as to whether the underlying block devices are available to the kernel 
from the outset.


Cheers,

--Kerin




[gentoo-user] Re: Moving the system from one disk to another

2010-04-04 Thread Kerin Millar

On 04/04/2010 20:05, meino.cra...@gmx.de wrote:


Hi,

I have to move my whole system from one disk to another
bigger one.

I think of doing as follows:
Boot a system via CD/DVD (knoppix for example).
Mount small disk read-only
Mount bigger disk read-write

cd into mountpoint of the first one
cp -a . ../

Seems to me slow but correct? Or?


cp -a is fine although, in my experience, I've found that rsync is more 
reliable:


rsync -av /mnt/oldrootfs/. /mnt/newrootfs/.

Note that -a covers almost everything but you may need the following 
additional options depending on how your filesystem has been used:


-H = preserve hard link
-A = preserve ACLs
-X = preserve extended attributes (in in doubt, recommended)

Whichever way you go about it, ensure that no pseudo-filesystem or bind 
mounts are present within "/mnt/oldrootfs" at the time.


Cheers,

--Kerin




Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 12:29 PM, Kerin Millar  wrote:

>
> Ah, that looks better. Not that I've pored over every line, but at first
> glance everything seems to be in order. There are no obvious gotchas that I
> can see, so I'm somewhat puzzled.

As am I!

>
> Here are a few random things that spring to mind though ...
>
> I would suggest switching off CONFIG_IDE. It may contend for control of your
> hardware with the AHCI driver, assuming that emulation/comptability mode is
> enabled in the BIOS.
>
> The device nodes may be unavailable at the time that they are needed, for
> some strange reason. If you mount the root filesystem from a livecd (with no
> bind mounts), try creating static nodes in dev/:
>
>  mknod /dev/md0 b 9 0
>  mknod /dev/md1 b 9 1
>  mknod /dev/md2 b 9 2
>  mknod /dev/md3 b 9 3

So this suggests that because I did the install from a running Gentoo
chroot that the mknod commands didn't stick? Somehow they were part
of, or because part of, the host Gentoo non-RAID install? Interesting.

I'll boot next ffrom the Live CD and try it.

>
> Note that the preferred minor of your array can be determined by examining
> any component partition. For instance, "mdadm -E /dev/sdb3".

That's what I thought from the install guide but it seemed others here
had other opions.

>
> Avoid manual specification of the RAID parameters. The kernel should be
> perfectly able to assemble the array by examining the superblocks of
> partitions of type "FD".
>
> Does it work if you specify "root=/dev/sdb3" or "root=/dev/sdc3"? With
> raid1, it's possible to mount just the component partition (although it will
> later result in a resync). The point is, it would at least confirm as to
> whether the underlying block devices are available to the kernel from the
> outset.

OK, this was interesting, and I suppose it depends on what you mean
'should work'. Clearly it gets much further, into the interactive
portion of the boot with the green asterics on the right. When it
finally gets to the md0 portion it says the the superblock does not
correctly specify an ext2 filesystem and asks for a password or
Control D. Control D reboots and entering the password results in a
(none) prompt and seems to require a hard reset. None the less it got
much further, but not to a usable state.

Off to do the Live CD work. Back in 30 minutes.

Cheers,
Mark



Re: [gentoo-user] Moving the system from one disk to another

2010-04-04 Thread covici
meino.cra...@gmx.de wrote:

> 
> Hi,
> 
> I have to move my whole system from one disk to another
> bigger one.
> 
> I think of doing as follows:
> Boot a system via CD/DVD (knoppix for example).
> Mount small disk read-only 
> Mount bigger disk read-write
> 
> cd into mountpoint of the first one
> cp -a . ../
> 
> Seems to me slow but correct? Or?
> 
> (I have to set the bootable flag of the correct partion
> additionally...)
> 
> I dont want to have a booting system afterwards, which "runs" for --
> say -- three month and suddenly hit a obscure bug due to my
> copy-commands, which only did it to 99.87% correct... ;)
> 
> I would like to preserve as much as possible of the file/directoy
> times ,,,
> 
> Or does a mystical command with s-tar a better job faster? 
> 
> Thank you very much in adance for any help!

I like rsync and be sure to say --numeric-ids or whatever to retain the
same userids for permissions, but otherwise you are good to go.

-- 
Your life is like a penny.  You're going to lose it.  The question is:
How do
you spend it?

 John Covici
 cov...@ccs.covici.com



Re: [gentoo-user] Re: Moving the system from one disk to another

2010-04-04 Thread Neil Bothwick
On Sun, 04 Apr 2010 20:35:11 +0100, Kerin Millar wrote:

> Whichever way you go about it, ensure that no pseudo-filesystem or bind 
> mounts are present within "/mnt/oldrootfs" at the time.

Use the -x option with rsync to stop it descending into other filesystems.


-- 
Neil Bothwick

Did you hear about the dyslexic devil worshiper?
He sold his soul to Santa!


signature.asc
Description: PGP signature


[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 04/04/2010 20:52, Mark Knecht wrote:

So this suggests that because I did the install from a running Gentoo
chroot that the mknod commands didn't stick? Somehow they were part
of, or because part of, the host Gentoo non-RAID install? Interesting.


I don't know what the handbook says these days, but I understand that 
it's lately taken to recommending a bind mount of /dev. If that's the 
case, then none of the static device nodes that are contained with the 
/dev directory within the stage3 tarball will actually make it on to the 
root filesystem because, at the time of unpacking, they will be 
redirected to the (volatile) tmpfs mount at /dev with respect to the 
livecd environment.


From the point of view of the problem you're having, it may not even 
matter but it's one thing to try anyway.


It's interesting that the component disks are available. In principle, 
there's no reason why the array should not be assembled. Here's an 
example of how it looks during the boot process on one of my systems:


  Command line: root=/dev/md2
  Kernel command line: root=/dev/md2 quiet
  ata1: SATA max UDMA/133 cmd 0xcc30 ctl 0xcc28 bmdma 0xcc40 irq 23
  ata2: SATA max UDMA/133 cmd 0xcc38 ctl 0xcc2c bmdma 0xcc48 irq 23
  md: raid1 personality registered for level 1
  md: Waiting for all devices to be available before autodetect
  md: If you don't use raid, use raid=noautodetect
  md: Autodetecting RAID arrays.
  md: Scanned 6 and added 6 devices.
  md: autorun ...
  md: considering sdb3 ...
  md:  adding sdb3 ...
  md: sdb2 has different UUID to sdb3
  md: sdb1 has different UUID to sdb3
  md:  adding sda3 ...
  md: sda2 has different UUID to sdb3
  md: sda1 has different UUID to sdb3
  md: created md2
  md: bind
  md: bind
  md: running: 
  md: kicking non-fresh sdb3 from array!
  md: unbind
  md: export_rdev(sdb3)
  raid1: raid set md2 active with 1 out of 2 mirrors
  md2: detected capacity change from 0 to 248798183424
  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: bind
  md: bind
  md: running: 
  md: kicking non-fresh sdb2 from array!
  md: unbind
  md: export_rdev(sdb2)
  raid1: raid set md1 active with 1 out of 2 mirrors
  md1: detected capacity change from 0 to 1085669376
  md: considering sdb1 ...
  md:  adding sdb1 ...
  md:  adding sda1 ...
  md: created md0

You might consider disabling the framebuffer temporarily, as it may 
impact upon your ability to see what's going on early during the boot 
process.


Cheers,

--Kerin




Re: [gentoo-user] alsa-update not in sync with kernel version

2010-04-04 Thread Neil Bothwick
On Sun, 4 Apr 2010 20:42:48 +0200, meino.cra...@gmx.de wrote:

> I am running a vanilla kernel (linux-2.6.32.11), This kernel uses
> alsa-1.0.21.
> 
> When doing the eix-sync-thingy, emerge always suggests to update
> to alsa-1.0.22.

The 1.0.22 userspace tools work fine with the drivers in 2.6.32.


-- 
Neil Bothwick

I have seen things you lusers would not believe.
I've seen Sun monitors on fire off the side of the multimedia lab.
I've seen NTU lights glitter in the dark near the Mail Gate.
All these things will be lost in time, like the root partition last
week. Time to die.


signature.asc
Description: PGP signature


[gentoo-user] Anyone ever emerged dev-libs/boost with FEATURES="test" and finished?

2010-04-04 Thread Lie Ryan
I'm running with full system FEATURES="test" on, and I have a couple of
programs that depended on dev-libs/boost. The boost testsuite always
fails in my computer due to insufficient disk space, I usually simply
skip the test for boost and just go on with the merge. But today, I
decided to let the testsuite run to completion; so in preparation for
that, I plugged in an external harddisk and made it so that
/var/tmp/portage points to an empty disk image in the external harddrive.

This setup works ok, and the testsuite is still running, however I saw
now that the disk image's is now taking ~18 GB (and counting) while "du
-sh" on /var/tmp/portage counted ~13GB.

So, the question is, has anyone successfully compiled and run
FEATURES="test" on boost and knows how much space the tests eat up in
the end?

I am suspecting of the possibility that maybe a testsuite gets into an
infinite loop while writing a file or something constantly eats up
diskspace. Or is it just that boost has an outrageously too extensive
testsuite and it will turn out ok if I just left it to run.




Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 1:06 PM, Kerin Millar  wrote:
> On 04/04/2010 20:52, Mark Knecht wrote:
>>
>> So this suggests that because I did the install from a running Gentoo
>> chroot that the mknod commands didn't stick? Somehow they were part
>> of, or because part of, the host Gentoo non-RAID install? Interesting.
>
> I don't know what the handbook says these days, but I understand that it's
> lately taken to recommending a bind mount of /dev. If that's the case, then
> none of the static device nodes that are contained with the /dev directory
> within the stage3 tarball will actually make it on to the root filesystem
> because, at the time of unpacking, they will be redirected to the (volatile)
> tmpfs mount at /dev with respect to the livecd environment.
>
> From the point of view of the problem you're having, it may not even matter
> but it's one thing to try anyway.
>
> It's interesting that the component disks are available. In principle,
> there's no reason why the array should not be assembled. Here's an example
> of how it looks during the boot process on one of my systems:
>
>  Command line: root=/dev/md2
>  Kernel command line: root=/dev/md2 quiet
>  ata1: SATA max UDMA/133 cmd 0xcc30 ctl 0xcc28 bmdma 0xcc40 irq 23
>  ata2: SATA max UDMA/133 cmd 0xcc38 ctl 0xcc2c bmdma 0xcc48 irq 23

>
> You might consider disabling the framebuffer temporarily, as it may impact
> upon your ability to see what's going on early during the boot process.
>
> Cheers,
>
> --Kerin

Hi Kerin,
   First, thanks for sticking with me on this. I really appreciate it.
Second, I apologize for the length of the reply but it's still not
working and I wanted to try and clearly show the steps I've taken.
Maybe you or someone else will see the step I'm missing.

   OK, more and more it's looking to me like on the RAID I'm just not
getting the /devmdX special file that has to be there to
mount/bind/whatever the hardware to. What creates it, other than
mknod? Can I do it by hand some other way? Read on...

1) Booted non-RAID and look in /dev for md*. md0 is there. I mount the
RAID and look in the directory /mnt/gentoo/dev/ for anything named
md*. There's nothing.

2) Booting with the Live CD I modprobe raid1, assemble the RAID, and
then do the recommended chroot:

livecd usr # cd /
livecd / # mount -t proc proc /mnt/gentoo/proc
livecd / # mount -o bind /dev /mnt/gentoo/dev
livecd / # cp -L /etc/resolv.conf /mnt/gentoo/etc/
livecd / # chroot /mnt/gentoo /bin/bash
livecd / # env-update && source /etc/profile

3) I look in /dev and still no md*. (There shouldn't be)

4) Because I used md3 to get into the RAID from the Live CD I create
some new devices, but specifically don't do md3:

livecd / # mknod /dev/md0 b 9 0
livecd / # mknod /dev/md1 b 9 1
livecd / # mknod /dev/md2 b 9 2
livecd / # mknod /dev/md4 b 9 4
livecd / # mknod /dev/md5 b 9 5

5) ls the directory and I see the ones I created plus md3 bound from
the chroot above:

livecd / # ls /dev/md*
/dev/md0  /dev/md1  /dev/md2  /dev/md3  /dev/md4  /dev/md5

/dev/md:
3

6) I exit the chroot and look again at what's now in the Live CD /dev.
As expected I still see all 6.

livecd / # exit
exit
livecd ~ #
 ls /dev/md*
/dev/md0  /dev/md1  /dev/md2  /dev/md3  /dev/md4  /dev/md5

/dev/md:
3
livecd ~ # df
Filesystem   1K-blocks  Used Available Use% Mounted on
tmpfs  3052532 29600   3022932   1% /
/dev/sr0117392117392 0 100% /mnt/cdrom
/dev/loop0   87424 87424 0 100% /mnt/livecd
udev 10240   216 10024   3% /dev
tmpfs  3052532  6152   3046380   1%
/mnt/livecd/lib64/firmware
tmpfs  3052532 0   3052532   0% /mnt/livecd/usr/portage
/dev/md3  30969528   2254188  27142180   8% /mnt/gentoo
livecd ~ #


7) Try booting RAID a couple of times with different command line
options. It still fails the same way.

8) Boot back to non-RAID and mount the RAID, this time as md0 just to
be different. I look in /dev and see only md0, as expected:

keeper ~ # df
Filesystem   1K-blocks  Used Available Use% Mounted on
/dev/sda3 30969600   7244840  22151596  25% /
udev 10240   228 10012   3% /dev
shm3053512 0   3053512   0% /dev/shm
/dev/md0  30969528   2254188  27142180   8% /mnt/gentoo
keeper ~ # ls /dev/md*
/dev/md0

/dev/md:
0
keeper ~ #

9) I look in /mnt/gentoo/dev to see if ANY md special files are there.
There are none:

keeper ~ # ls -al /mnt/gentoo/dev/md*
ls: cannot access /mnt/gentoo/dev/md*: No such file or directory
keeper ~ #


All the other stuff is there, but not the special files I created
while in the chroot.

So, to me, this comes down to something like when I'm booting /dev/md0
or md3 isn't available so the kernel cannot mount the RAID anywhere.
What creates the special file, at least by hand, is mknod, and for
some reason I'm unable to make t

[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 04/04/2010 23:16, Mark Knecht wrote:

First, thanks for sticking with me on this. I really appreciate it.
Second, I apologize for the length of the reply but it's still not
working and I wanted to try and clearly show the steps I've taken.
Maybe you or someone else will see the step I'm missing.


[snip]


I don't know what to try next.


OK, I think I now understand what's happening here. I regret that I did 
not recall this earlier but only the original RAID superblock format 
(version 0.90.00) is supported for automatic assembly! I have two 
servers that are set up in a similar way as your box, and they both use 
this format. It's possible that the docs may be out of date but 
/usr/src/linux/Documentation/md.txt says:


"When md is compiled into the kernel (not as module), partitions of type 
0xfd are scanned and automatically assembled into RAID arrays. This 
autodetection may be suppressed with the kernel parameter 
"raid=noautodetect".  As of kernel 2.6.9, only drives with a type 0 
superblock can be autodetected and run at boot time."


Also, look at this:

http://www.mail-archive.com/linux-r...@vger.kernel.org/msg06215.html

To quote Neil Brown:

"v0.90 can be used with 'in kernel autodetect' (i.e. partition type 
0xfd). v1 cannot (I consider this an improvement :-)"


Well, I can't say I agree with him there.

Anyway, it seems that you're using the 1.1 superblock format. So, what 
options does this leave you with?


a) Backup the root filesystem, and re-create the array with the regular
   superblock format. If necessary, coerce mdadm with -e 0 but it should
   be a default.

b) Rely on userspace tools to assemble the array. This means either
   having the root filesystem off raid, or using an initrd/initramfs
   image.

I'd got for the first option as it keeps things simple and the benefits 
of the v1 format are nebulous in practical terms.


Cheers,

--Kerin




Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 3:47 PM, Kerin Millar  wrote:
> On 04/04/2010 23:16, Mark Knecht wrote:
>>
>>    First, thanks for sticking with me on this. I really appreciate it.
>> Second, I apologize for the length of the reply but it's still not
>> working and I wanted to try and clearly show the steps I've taken.
>> Maybe you or someone else will see the step I'm missing.
>
> [snip]
>
>> I don't know what to try next.
>
> OK, I think I now understand what's happening here. I regret that I did not
> recall this earlier but only the original RAID superblock format (version
> 0.90.00) is supported for automatic assembly! I have two servers that are
> set up in a similar way as your box, and they both use this format. It's
> possible that the docs may be out of date but
> /usr/src/linux/Documentation/md.txt says:
>
> "When md is compiled into the kernel (not as module), partitions of type
> 0xfd are scanned and automatically assembled into RAID arrays. This
> autodetection may be suppressed with the kernel parameter
> "raid=noautodetect".  As of kernel 2.6.9, only drives with a type 0
> superblock can be autodetected and run at boot time."
>
> Also, look at this:
>
> http://www.mail-archive.com/linux-r...@vger.kernel.org/msg06215.html
>
> To quote Neil Brown:
>
> "v0.90 can be used with 'in kernel autodetect' (i.e. partition type 0xfd).
> v1 cannot (I consider this an improvement :-)"
>
> Well, I can't say I agree with him there.
>
> Anyway, it seems that you're using the 1.1 superblock format. So, what
> options does this leave you with?
>
> a) Backup the root filesystem, and re-create the array with the regular
>   superblock format. If necessary, coerce mdadm with -e 0 but it should
>   be a default.
>
> b) Rely on userspace tools to assemble the array. This means either
>   having the root filesystem off raid, or using an initrd/initramfs
>   image.
>
> I'd got for the first option as it keeps things simple and the benefits of
> the v1 format are nebulous in practical terms.
>
> Cheers,
>
> --Kerin
>
>
>

Hi,
   From my post this morning:

"No problem supplying it. I did the rebuild this morning but forced
metadata to Type 1.0. No change as you suggested there wouldn't be."

I guess I didn't post it there but what I meant by that was the following:

1) If you don't specify metadata then you get the newest - I think
that's currently ver. 1.2 or something.

2) I tried 1.0 this morning (shown below) which didn't fix it.

(commands used are below)

I will immediately try 0.90 as I have no problem with the limitations
at this time:

  0, 0.90
 Use  the  original  0.90  format superblock.
This format limits arrays to 28 component
 devices and limits component devices of levels 1
and greater to 2 terabytes.

I should hopefully know in an hour or two how this worked.

Thanks for the help!

Cheers,
Mark

keeper ~ # mdadm --create /dev/md0 --level=1 --raid-devices=2
/dev/sdb3 /dev/sdc3
mdadm: Note: this array has metadata at the start and
   may not be suitable as a boot device.  If you plan to
   store '/' or '/boot' on this device please ensure that
   your boot-loader understands md/v1.x metadata, or use
   --metadata=1.0
mdadm: Note: this array has metadata at the start and
   may not be suitable as a boot device.  If you plan to
   store '/' or '/boot' on this device please ensure that
   your boot-loader understands md/v1.x metadata, or use
   --metadata=1.0
Continue creating array? n
mdadm: create aborted.
keeper ~ #  mdadm --create /dev/md0 --level=1 --raid-devices=2
--metadata=1.0 /dev/sdb3 /dev/sdc3
mdadm: array /dev/md0 started.
keeper ~ # cat /proc/mdstat
Personalities : [raid1]
md0 : active raid1 sdc3[1] sdb3[0]
 31463228 blocks super 1.0 [2/2] [UU]
 [>]  resync =  3.9% (1241664/31463228)
finish=5.2min speed=95512K/sec

unused devices: 
keeper ~ #



[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 05/04/2010 00:12, Mark Knecht wrote:

1) If you don't specify metadata then you get the newest - I think
that's currently ver. 1.2 or something.


Interesting. I suppose that might be a change in mdadm-3.0 (a version 
which I have yet to use to create any new arrays). However, that would 
contradict the man page which still says:


"0, 0.90, default"


2) I tried 1.0 this morning (shown below) which didn't fix it.


Right. Any version above in the 1 series (1, 1.0, 1.1, 1.2) will not 
work. I'm certain that reverting to the original format is going to 
resolve the issue and that we've just been barking up the wrong tree(s) 
hitherto.


--Kerin




Re: [gentoo-user] Re: Moving the system from one disk to another

2010-04-04 Thread Kacper Kopczyński
Dnia 2010-04-04, o godz. 21:04:03
Neil Bothwick  napisał(a):

> On Sun, 04 Apr 2010 20:35:11 +0100, Kerin Millar wrote:
> 
> > Whichever way you go about it, ensure that no pseudo-filesystem or
> > bind mounts are present within "/mnt/oldrootfs" at the time.
> 
> Use the -x option with rsync to stop it descending into other
> filesystems.
> 
> 

AFAIK

"mount --bind / /somewhere" and rsync'ing /somewhere/ instead of / would
be more useful then "-x" option - stage1,2,3 has static /dev entries
which should also be copied. Since udev mounts it with tmpfs, rsync
with -x would skip those entries (static and from tmpfs).

I suppose you can ignore static /dev if you use initrd.

Since author of this thread wants to mount filesystem(s) of "the
system" from livecd of some kind, there is no point in using any of
ideas in this or previous email - there will be no other filesystems
mounted.

I often use that trick with /somewhere/ to backup live system from
laptop to external drive. But it does not work well with innodb...

man mount
man rsync

good luck

-- 
Kacper Kopczyński



Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 4:51 PM, Kerin Millar  wrote:
> On 05/04/2010 00:12, Mark Knecht wrote:
>>
>> 1) If you don't specify metadata then you get the newest - I think
>> that's currently ver. 1.2 or something.
>
> Interesting. I suppose that might be a change in mdadm-3.0 (a version which
> I have yet to use to create any new arrays). However, that would contradict
> the man page which still says:
>
> "0, 0.90, default"
>
>> 2) I tried 1.0 this morning (shown below) which didn't fix it.
>
> Right. Any version above in the 1 series (1, 1.0, 1.1, 1.2) will not work.
> I'm certain that reverting to the original format is going to resolve the
> issue and that we've just been barking up the wrong tree(s) hitherto.
>
> --Kerin

I'm emerging gentoo-sources in the chroot now.

One thing about this that still confuses me is where /dev/md3, or
whatever, comes from when I boot if the the mknod command is never
executed within the chrrot. (As per the install guide.) Not a big deal
to proceed and see what happens. Maybe the kernel just creates it
based on discovering the RAID? Or it makes it because I explicitly
define it at the command line?

As I say, no big deal to just push forward but that's still a question
for me at this point.

Cheers,
Mark



[gentoo-user] Re: Moving the system from one disk to another

2010-04-04 Thread Kerin Millar

On 05/04/2010 00:51, Kacper Kopczyński wrote:

Dnia 2010-04-04, o godz. 21:04:03
Neil Bothwick  napisał(a):


On Sun, 04 Apr 2010 20:35:11 +0100, Kerin Millar wrote:


Whichever way you go about it, ensure that no pseudo-filesystem or
bind mounts are present within "/mnt/oldrootfs" at the time.


Use the -x option with rsync to stop it descending into other
filesystems.




AFAIK

"mount --bind / /somewhere" and rsync'ing /somewhere/ instead of / would
be more useful then "-x" option - stage1,2,3 has static /dev entries
which should also be copied. Since udev mounts it with tmpfs, rsync
with -x would skip those entries (static and from tmpfs).


Well, no, because my response was based on the fact that the duplication 
will be carried out from an alternate environment provided by a CD/DVD, 
as Meino clearly stated in the original post. Thus, bind mounts, 
pseudo-filesystems and chroots need not come into the equation 
whatsoever. Indeed, it's the very same concern that you express which 
resulted in my recommendation to avoid such shenanigans and keep it 
simple. Ergo, just mount the root filesystem - nothing else - and copy 
it as-is. Static /dev entries would be copied without issue, as would 
everything else. It really couldn't be simpler.


You post hinges on the notion that he would be performing the process 
while booted from the system he is duplicating, in which case your 
advice would, of course, be entirely sensible. Ergo, he would indeed be 
best advised to bind mount / to a temporary directory and use that as 
the source for the exact reasons that you mention. I personally would 
not recommend doing it under these circumstances but it can certainly be 
done (though I'd suggest dropping to runlevel 1 first).


Cheers,

--Kerin




[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Kerin Millar

On 05/04/2010 00:58, Mark Knecht wrote:

One thing about this that still confuses me is where /dev/md3, or
whatever, comes from when I boot if the the mknod command is never
executed within the chrrot. (As per the install guide.) Not a big deal
to proceed and see what happens. Maybe the kernel just creates it
based on discovering the RAID? Or it makes it because I explicitly
define it at the command line?


Well, it shouldn't matter. The md block device will be initialised by 
the kernel as soon as it loads, whereupon it will be resolved internally 
by its registered major/minor numbers for the purpose of mounting the 
root filesystem (that's the "9, 0" that you referred to earlier in the 
thread). Once the root filesystem is mounted read-only, it proceeds to 
load init.


Later, the device node will need to be present - for instance, when 
fstab is parsed - but udev will have taken care of it by that time. That 
is, udev will manifest the device node in a tmpfs filesystem which is 
mounted at /dev and dynamically populated early on during the boot process.


Cheers,

--Kerin




Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 4:58 PM, Mark Knecht  wrote:
> On Sun, Apr 4, 2010 at 4:51 PM, Kerin Millar  wrote:
>> On 05/04/2010 00:12, Mark Knecht wrote:
>>>
>>> 1) If you don't specify metadata then you get the newest - I think
>>> that's currently ver. 1.2 or something.
>>
>> Interesting. I suppose that might be a change in mdadm-3.0 (a version which
>> I have yet to use to create any new arrays). However, that would contradict
>> the man page which still says:
>>
>> "0, 0.90, default"
>>
>>> 2) I tried 1.0 this morning (shown below) which didn't fix it.
>>
>> Right. Any version above in the 1 series (1, 1.0, 1.1, 1.2) will not work.
>> I'm certain that reverting to the original format is going to resolve the
>> issue and that we've just been barking up the wrong tree(s) hitherto.
>>
>> --Kerin
>
> I'm emerging gentoo-sources in the chroot now.
>
> One thing about this that still confuses me is where /dev/md3, or
> whatever, comes from when I boot if the the mknod command is never
> executed within the chrrot. (As per the install guide.) Not a big deal
> to proceed and see what happens. Maybe the kernel just creates it
> based on discovering the RAID? Or it makes it because I explicitly
> define it at the command line?
>
> As I say, no big deal to just push forward but that's still a question
> for me at this point.
>
> Cheers,
> Mark
>

OK, I'm up and running now.

Using --metadata=0.90 when first creating the RAID was the solution.

It seems that md0 is (I guess) there by default and then md3 gets
created by the kernel extra command line stuff I guess:

k2 ~ # ls /dev/md*
/dev/md0  /dev/md3

/dev/md:
0  3  3_0
k2 ~ #

localhost ~ # df
Filesystem   1K-blocks  Used Available Use% Mounted on
/dev/md3  41294780   2258892  36938208   6% /
udev 10240   232 10008   3% /dev
shm3053480 0   3053480   0% /dev/shm

Thanks for all the help today Kerin. I really appreciate it!

Cheers,
Mark



[gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread walt

On 04/04/2010 07:20 AM, Mark Knecht wrote:

  keeper ~ # diff /usr/src/linux/.config /mnt/gentoo/usr/src/linux/.config
4c4
<  # Mon Mar 29 01:02:31 2010
---

# Sun Apr  4 06:28:53 2010

893,912c893,906
<  CONFIG_MD_LINEAR=m
<  CONFIG_MD_RAID0=m


Hi Mark,

Interesting thread, and I'm learning a lot from following along.  I know
very little about raid so I can benefit from nearly any question.

Just one suggestion about diffs, though.  Most people who post and/or test
patches will expect the 'unified' diff format, which is generated by using
'diff -u'.  Much easier for humans to parse.




Re: [gentoo-user] Re: How does grub assemble a RAID1 for / ??

2010-04-04 Thread Mark Knecht
On Sun, Apr 4, 2010 at 5:47 PM, walt  wrote:
> On 04/04/2010 07:20 AM, Mark Knecht wrote:
>>
>>  keeper ~ # diff /usr/src/linux/.config /mnt/gentoo/usr/src/linux/.config
>> 4c4
>> <  # Mon Mar 29 01:02:31 2010
>> ---
>>>
>>> # Sun Apr  4 06:28:53 2010
>>
>> 893,912c893,906
>> <  CONFIG_MD_LINEAR=m
>> <  CONFIG_MD_RAID0=m
>
> Hi Mark,
>
> Interesting thread, and I'm learning a lot from following along.  I know
> very little about raid so I can benefit from nearly any question.
>
> Just one suggestion about diffs, though.  Most people who post and/or test
> patches will expect the 'unified' diff format, which is generated by using
> 'diff -u'.  Much easier for humans to parse.
>
Walt,
   Good to know about the diff stuff. I hope I can remember that next
time. Glad if this thread can help others, either now or in the
future.

   I do intend to follow up with the mdadm guys about the actual
metadata requirements when I get a chance.

   I'm just finishing emerge -DuN @world on the new RAID build. Fast
with an 8 core processor and Enterprise class RAID drives. Can hardly
wait for the big 12 core machine with two RAIDs in it to start
running.

Cheers,
Mark



[gentoo-user] Re: alsa-update not in sync with kernel version

2010-04-04 Thread walt

On 04/04/2010 11:42 AM, meino.cra...@gmx.de wrote:


Hi,

I am running a vanilla kernel (linux-2.6.32.11), This kernel uses
alsa-1.0.21.

When doing the eix-sync-thingy, emerge always suggests to update
to alsa-1.0.22.


Do you have media-sound/alsa-driver installed?  If so, that is the
cause of your problem -- just emerge -C alsa-driver.  That package
is only for people who are testing/debugging alsa-drivers (or using
prehistoric kernels on new hardware).





[gentoo-user] Re: Moving the system from one disk to another

2010-04-04 Thread walt

On 04/04/2010 01:04 PM, Neil Bothwick wrote:

On Sun, 04 Apr 2010 20:35:11 +0100, Kerin Millar wrote:


Whichever way you go about it, ensure that no pseudo-filesystem or bind
mounts are present within "/mnt/oldrootfs" at the time.


Use the -x option with rsync to stop it descending into other filesystems.


This is directed to all of you gurus who replied to Meino's post:

Meino's unstated assumption is that his new (larger) disk is already formatted
(possibly partitioned?) before he copies the existing filesystem to it.

IIUC the new disk will then be unbootable until grub or equivalent is installed
on the new disk.  Does this seem correct, or not?

My instinct is to use dd to duplicate the entire old disk to the new 
(unformatted)
disk and then use gparted to twiddle it from there. (But I do love a puzzle ;o)




[gentoo-user] Re: Moving the system from one disk to another

2010-04-04 Thread Kerin Millar

On 05/04/2010 02:34, walt wrote:

On 04/04/2010 01:04 PM, Neil Bothwick wrote:

On Sun, 04 Apr 2010 20:35:11 +0100, Kerin Millar wrote:


Whichever way you go about it, ensure that no pseudo-filesystem or bind
mounts are present within "/mnt/oldrootfs" at the time.


Use the -x option with rsync to stop it descending into other
filesystems.


This is directed to all of you gurus who replied to Meino's post:

Meino's unstated assumption is that his new (larger) disk is already
formatted
(possibly partitioned?) before he copies the existing filesystem to it.

IIUC the new disk will then be unbootable until grub or equivalent is
installed
on the new disk. Does this seem correct, or not?


Absolutely correct. Two commands from the grub shell and job done :)



My instinct is to use dd to duplicate the entire old disk to the new
(unformatted)
disk and then use gparted to twiddle it from there. (But I do love a
puzzle ;o)


In general, I'm a proponent of copying filesystems, as opposed to 
copying entire block devices or disks. That's not to say that there 
aren't some situations where the latter approach makes sense.


Note that it's possible to copy just the portion of the first sector 
that contains bootloader code as thus:


  dd if=/dev/sda of=/dev/sdb bs=446 count=1

NOTE: that's 446 as opposed to 512 as the latter would result in the 
partition table being copied too, which would be most undesirable.


Cheers,

--Kerin




[gentoo-user] ~~Hi~~

2010-04-04 Thread AJ Spagnoletti
http://sites.google.com/site/gni8hy9ojm/icfa5w



Re: [gentoo-user] alsa-update not in sync with kernel version

2010-04-04 Thread meino . cramer
Neil Bothwick  [10-04-05 01:32]:
> On Sun, 4 Apr 2010 20:42:48 +0200, meino.cra...@gmx.de wrote:
> 
> > I am running a vanilla kernel (linux-2.6.32.11), This kernel uses
> > alsa-1.0.21.
> > 
> > When doing the eix-sync-thingy, emerge always suggests to update
> > to alsa-1.0.22.
> 
> The 1.0.22 userspace tools work fine with the drivers in 2.6.32.

  Nice to hear, Neil, but is this also true for other combinations
  of versions in the near or fat future? 
  That was the reason of my question... 

  mcc

> -- 
> Neil Bothwick
> 
> I have seen things you lusers would not believe.
> I've seen Sun monitors on fire off the side of the multimedia lab.
> I've seen NTU lights glitter in the dark near the Mail Gate.
> All these things will be lost in time, like the root partition last
> week. Time to die.



-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




Re: [gentoo-user] Re: alsa-update not in sync with kernel version

2010-04-04 Thread meino . cramer
walt  [10-04-05 05:02]:
> On 04/04/2010 11:42 AM, meino.cra...@gmx.de wrote:
> >
> >Hi,
> >
> >I am running a vanilla kernel (linux-2.6.32.11), This kernel uses
> >alsa-1.0.21.
> >
> >When doing the eix-sync-thingy, emerge always suggests to update
> >to alsa-1.0.22.
> 
> Do you have media-sound/alsa-driver installed?  If so, that is the
> cause of your problem -- just emerge -C alsa-driver.  That package
> is only for people who are testing/debugging alsa-drivers (or using
> prehistoric kernels on new hardware).
> 
> 
Hi,

what's about people who compile software which needs the alsa-stuff,
for example libraries and headers?

mcc


-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.




[gentoo-user] ZSH: Gentoo-completion...how to modifiy?

2010-04-04 Thread meino . cramer

Hi,

adding Gentoo/emerge related stuff to the completion system of the zsh
is nice...but getting a dark blue color for parts of the prompt with
that is not.

Where can I tuirn what to modifiy the color or get back my previous
prompt?

Best regards,
mcc


-- 
Please don't send me any Word- or Powerpoint-Attachments
unless it's absolutely neccessary. - Send simply Text.
See http://www.gnu.org/philosophy/no-word-attachments.html
In a world without fences and walls nobody needs gates and windows.