Re: Some LFS 6.5 - 6.6 Inconsistencies

2010-06-08 Thread Simon Geard
On Mon, 2010-06-07 at 17:45 -0500, Bruce Dubbs wrote:
 That's not so easy.  We create the book with Docbook xml.  I don't know 
 of a way to to do that.  We do have both a change log and a What's new 
 section.  We are trying to do a new release every 6 months.  If you look 
 at What's new, almost every package changes each time, but most use 
 the instructions unchanged.

Yeah, I generally work off the Changelog page when updating the scripts
I build everything with, working up the list from whatever date I last
built against. Works for me - Changelog open in one tab, and the index
in a second one.

Simon.


signature.asc
Description: This is a digitally signed message part
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Glibc Make Error - Pass 1, Chapter 5.7, LFS Book 6.6

2010-06-08 Thread Rademaker, Pascal (Dealis)
Hello everybody,

I am new to this mailing list and this is also my first try to build a LFS. I 
am using Linux for several years now and decided now to try to build my own 
Linux.

Ok, now for my building environment. If there are any infos missing, just ask:

Base system: Debian kernel 2.6.26-2-686
Minmal system installed, no X
I am running the system as a vmware machine

Ok, now to my problem. I tried to follow the book word by word. I say try 
because during my last try I mixed up some paths and the error occured so I 
thought I start all over again. Now all the paths are (hopefully) correct, but 
the same error occurs. 

The compilation of the binutils, gcc, gmp and mpfr went just fine without any 
errors ... or I didn´t see them but it looks all good to me.

Anyway, during the make of glibc I noticed that he failed to compile a 
regular expression (see log for details). I don´t know if that is important. 
Finally he breaks down when he tries to make target (Log: No rule to make 
target `/mnt/lfs/sources/glibc-build/Versions.all', needed by 
`/mnt/lfs/sources/glibc-build/abi-versions.h'.  Stop.) 

??? I absolutely don´t have any clue what to do and what to fix! I guess the 
scripts are all good, so I don´t want to touch them. Anyone with an idea what 
to do? 

I would apreciate it very much if there would be someone who could help me or 
give me a hint! Many thanks in advance.

If there are any infromations missing, please ask, ok?

Thanks and greetings
Pascal


#
--BEGIN CODE:--

make -r PARALLELMFLAGS= CVSOPTS= -C ../glibc-2.11.1 objdir=`pwd` all
make[1]: Entering directory `/mnt/lfs/sources/glibc-2.11.1'
(echo 'sysd-rules-sysdirs := sysdeps/i386/elf 
nptl/sysdeps/unix/sysv/linux/i386/i686 sysdeps/unix/sysv/linux/i386/i686 
nptl/sysdeps/unix/sysv/linux/i386 sysdeps/unix/sysv/linux/i386 
nptl/sysdeps/unix/sysv/linux nptl/sysdeps/pthread sysdeps/pthread 
sysdeps/unix/sysv/linux sysdeps/gnu sysdeps/unix/common sysdeps/unix/mman 
sysdeps/unix/inet sysdeps/unix/sysv/i386 nptl/sysdeps/unix/sysv 
sysdeps/unix/sysv sysdeps/unix/i386 nptl/sysdeps/unix sysdeps/unix 
sysdeps/posix sysdeps/i386/i686/fpu nptl/sysdeps/i386/i686 sysdeps/i386/i686 
sysdeps/i386/i486 nptl/sysdeps/i386/i486 sysdeps/i386/fpu nptl/sysdeps/i386 
sysdeps/i386 sysdeps/wordsize-32 sysdeps/ieee754/ldbl-96 sysdeps/ieee754/dbl-64 
sysdeps/ieee754/flt-32 sysdeps/ieee754 sysdeps/generic/elf sysdeps/generic';
\
 for dir in sysdeps/i386/elf nptl/sysdeps/unix/sysv/linux/i386/i686 
sysdeps/unix/sysv/linux/i386/i686 nptl/sysdeps/unix/sysv/linux/i386 
sysdeps/unix/sysv/linux/i386 nptl/sysdeps/unix/sysv/linux nptl/sysdeps/pthread 
sysdeps/pthread sysdeps/unix/sysv/linux sysdeps/gnu sysdeps/unix/common 
sysdeps/unix/mman sysdeps/unix/inet sysdeps/unix/sysv/i386 
nptl/sysdeps/unix/sysv sysdeps/unix/sysv sysdeps/unix/i386 nptl/sysdeps/unix 
sysdeps/unix sysdeps/posix sysdeps/i386/i686/fpu nptl/sysdeps/i386/i686 
sysdeps/i386/i686 sysdeps/i386/i486 nptl/sysdeps/i386/i486 sysdeps/i386/fpu 
nptl/sysdeps/i386 sysdeps/i386 sysdeps/wordsize-32 sysdeps/ieee754/ldbl-96 
sysdeps/ieee754/dbl-64 sysdeps/ieee754/flt-32 sysdeps/ieee754 
sysdeps/generic/elf sysdeps/generic; do   \
   case $dir in \
   /*) ;; \
   *) dir=\$(..)$dir ;; \
   esac;  \
   asm='.S .s';   \
  \
   for o in .o .os .op .og .ob .oS; do\
 set % % rtld-% % m_% s_% ptw-% %;\
 while [ $# -ge 2 ]; do   \
   t=$1; shift;   \
   d=$1; shift;   \
   v=${t%%%}; [ x$v = x ] || v=\$(${v}CPPFLAGS);  \
   for s in $asm .c; do   \
 echo \$(objpfx)$t$o: $dir/$d$s \$(before-compile);  \
 echo  \$(compile-command$s) $v;\
   done;  \
 done;\
   done;  \
   echo \$(inst_includedir)/%.h: $dir/%.h \$(+force);   \
   echo\$(do-install);  \
 done;\
 echo 'sysd-rules-done = t')  /mnt/lfs/sources/glibc-build/sysd-rulesT
mv -f /mnt/lfs/sources/glibc-build/sysd-rulesT 

Re: Glibc Make Error - Pass 1, Chapter 5.7, LFS Book 6.6

2010-06-08 Thread Andrew Benton
On 08/06/10 10:05, Rademaker, Pascal (Dealis) wrote:
 mawk: scripts/gen-sorted.awk: line 19: regular expression compile failed
 (bad class -- [], [^] or [)
 /[^
 mawk: scripts/gen-sorted.awk: line 19: syntax error at or near ]
 mawk: scripts/gen-sorted.awk: line 19: runaway regular expression /, ,
 subd ...

Read the preface
http://www.linuxfromscratch.org/lfs/view/6.6/prologue/hostreqs.html

You need to install gawk. Mawk can't compile glibc.

Andy
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


AW: Glibc Make Error - Pass 1, Chapter 5.7, LFS Book 6.6

2010-06-08 Thread Rademaker, Pascal (Dealis)
Ups, that could be the point!

Many, many thanks Andy!!!

I will report again, but I guess, that´s it!

Greetings
Pascal 

-Ursprüngliche Nachricht-
Von: lfs-support-boun...@linuxfromscratch.org 
[mailto:lfs-support-boun...@linuxfromscratch.org] Im Auftrag von Andrew Benton
Gesendet: Dienstag, 8. Juni 2010 12:28
An: lfs-support@linuxfromscratch.org
Betreff: Re: Glibc Make Error - Pass 1, Chapter 5.7, LFS Book 6.6

On 08/06/10 10:05, Rademaker, Pascal (Dealis) wrote:
 mawk: scripts/gen-sorted.awk: line 19: regular expression compile 
 failed (bad class -- [], [^] or [) /[^
 mawk: scripts/gen-sorted.awk: line 19: syntax error at or near ]
 mawk: scripts/gen-sorted.awk: line 19: runaway regular expression /, 
 , subd ...

Read the preface
http://www.linuxfromscratch.org/lfs/view/6.6/prologue/hostreqs.html

You need to install gawk. Mawk can't compile glibc.

Andy
--
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: LFS-6.6, Stage2, glibc, nscd.c:442

2010-06-08 Thread Andrew Benton
On 07/06/10 16:35, linux fan wrote:
 # Hack to solve glibc __stack_chk_guard cross compile (  2.4 :)
 # this schpeel in LFS-6.6 ch5 gcc-pass1 and ch5 gcc-pass2 after unpack:
 glibc=$(ls  /lib/libc-*.so)
 read j1 v[0] v[1] v[2] j2  ${glibc//[-.]/ }
 if (( v[0]  2 )) || (( v[1]  4 ))  [ -f gcc/configure ]; then

shouldn't that be 
if (( ${v[0]}   2 ))  (( ${v[1]}  4 ))

# kick it
sed -i -e '/# Test for stack protector support in target C library/ {
a\
 gcc_cv_libc_provides_ssp=yes
  } ' gcc/configure

can be reduced to:

sed -i '/k prot/agcc_cv_libc_provides_ssp=yes' ../gcc-4.5.0/gcc/configure

so the whole thing can be reduced to:

v=($(ls  /lib/libc-*.so | sed 's/[.-]/ /g'))
[ (( ${v[1]}   2 ))  (( ${v[2]}  4 )) ] 
sed -i '/k prot/agcc_cv_libc_provides_ssp=yes' ../gcc-4.5.0/gcc/configure

Sorry for picking nits. It looks good and solves a problem I had due to 
one of my deviations. 
Thanks

Andy

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: Some LFS 6.5 - 6.6 Inconsistencies

2010-06-08 Thread Neal Murphy
  That's not so easy.  We create the book with Docbook xml.  I don't know
  of a way to to do that.  We do have both a change log and a What's new
  section.  We are trying to do a new release every 6 months.  If you look
  at What's new, almost every package changes each time, but most use
  the instructions unchanged.

 Yeah, I generally work off the Changelog page when updating the scripts
 I build everything with, working up the list from whatever date I last
 built against. Works for me - Changelog open in one tab, and the index
 in a second one.

FYI. This link might be useful: 
http://www.sagehill.net/docbookxsl/Changebars.html
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: LFS-6.6, Stage2, glibc, nscd.c:442

2010-06-08 Thread linux fan
On 6/8/10, Andrew Benton b3n...@gmail.com wrote:

 shouldn't that be
 if (( ${v[0]}   2 ))  (( ${v[1]}  4 ))


or maybe (( v[0] ==  2 ))  (( v[1]  4 ))

... bash (( allowed me to omit $ and {} around variables/arrays ))

But in the target lfs-6.6, glibc  2.4 is true, so the test isn't even needed.
That's the funny thing. Why did they look at the host to see what will
be on the target in this stage in a cross compile situation, when they
have no way of knowing what it will be? It seems like there should be
one of those --switches allowing the user to specify a thing like
this.


 Sorry for picking nits. It looks good and solves a problem I had due to
 one of my deviations.

You are welcome to pick all the nits you want. I don't care.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: LFS-6.6, Stage2, glibc, nscd.c:442

2010-06-08 Thread linux fan
On 6/8/10, Andrew Benton b3n...@gmail.com wrote:

 so the whole thing can be reduced to:

 v=($(ls  /lib/libc-*.so | sed 's/[.-]/ /g'))
 [ (( ${v[1]}   2 ))  (( ${v[2]}  4 )) ] 
 sed -i '/k prot/agcc_cv_libc_provides_ssp=yes' ../gcc-4.5.0/gcc/configure


[ $(ls  /lib/libc-*.so \
 | sed 's/[.-]/ /g' \
 | awk '{print ($23  $34) ? foo : bar}') == foo ] 
 sed -i '/k prot/agcc_cv_libc_provides_ssp=yes' ../gcc-4.5.0/gcc/configure

Please pardon me being silly.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Build Runlevel

2010-06-08 Thread Paul Rogers
I don't recall the book saying anything about it, possibly runlevel
3 is so typical it has never come up, but as I mentioned a week ago
or so, I think there would be an advantage to building LFS within
runlevel 2--where there's no network running, no chance of some
external attack on a vulnerable system midstream.  It's easier than
pulling the plug.  Last night I discovered the perl tests really
don't like that!  Some want to ping localhost, etc.  I suppose it's
legitimate to expect the host to provide a protected environment,
but that newly minted LFS system really shouldn't be connected to
a network until it's armored-up.
-- 
Paul Rogers
paulgrog...@fastmail.fm
http://www.xprt.net/~pgrogers/
Rogers' Second Law: Everything you do communicates.
(I do not personally endorse any additions after this line. TANSTAAFL :-)



-- 
http://www.fastmail.fm - Same, same, but different...

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: Glibc Make Error - Pass 1, Chapter 5.7, LFS Book 6.6

2010-06-08 Thread Paul Rogers
 mawk: scripts/gen-sorted.awk: line 19: regular expression compile failed
 (bad class -- [], [^] or [)
 /[^
 mawk: scripts/gen-sorted.awk: line 19: syntax error at or near ]
 mawk: scripts/gen-sorted.awk: line 19: runaway regular expression /, ,

I've never used mawk, so I'm not familiar how similar it may be to gawk,
but gawk is what the Host System Requirements specify.
-- 
Paul Rogers
paulgrog...@fastmail.fm
http://www.xprt.net/~pgrogers/
Rogers' Second Law: Everything you do communicates.
(I do not personally endorse any additions after this line. TANSTAAFL :-)



-- 
http://www.fastmail.fm - A fast, anti-spam email service.

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: Build Runlevel

2010-06-08 Thread Bruce Dubbs
Paul Rogers wrote:
 I don't recall the book saying anything about it, possibly runlevel
 3 is so typical it has never come up, but as I mentioned a week ago
 or so, I think there would be an advantage to building LFS within
 runlevel 2--where there's no network running, no chance of some
 external attack on a vulnerable system midstream.  It's easier than
 pulling the plug.  Last night I discovered the perl tests really
 don't like that!  Some want to ping localhost, etc.  I suppose it's
 legitimate to expect the host to provide a protected environment,
 but that newly minted LFS system really shouldn't be connected to
 a network until it's armored-up.

I understand your concern, but armored-up is really not necessary.  In 
order to make any type of connection to the new system, a process must 
be listening to a port.  There are no such processes in lfs.  The ping 
of localhost is not technically a TCP/IP process.  It never goes on the 
wire.

After boot, the telnet, ftp, and some other clients are available, but 
we specifically --disable-servers in inetutils.

   -- Bruce

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: Some LFS 6.5 - 6.6 Inconsistencies

2010-06-08 Thread Bruce Dubbs
Neal Murphy wrote:
 That's not so easy.  We create the book with Docbook xml.  I don't know
 of a way to to do that.  We do have both a change log and a What's new
 section.  We are trying to do a new release every 6 months.  If you look
 at What's new, almost every package changes each time, but most use
 the instructions unchanged.
 Yeah, I generally work off the Changelog page when updating the scripts
 I build everything with, working up the list from whatever date I last
 built against. Works for me - Changelog open in one tab, and the index
 in a second one.
 
 FYI. This link might be useful: 
 http://www.sagehill.net/docbookxsl/Changebars.html

Thanks.  That may be doable, but it looks like a fairly significant 
effort to get all the details right.  The html doesn't support change 
bars, but changes can be highlighted in color/underlining, etc.  My 
thought would be to to show additions and changes, but hide deletions.

I added a ticket at low priority so we don't forget about this.

   -- Bruce

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: Glibc Make Error - Pass 1, Chapter 5.7, LFS Book 6.6

2010-06-08 Thread Neal Murphy
On Tuesday 08 June 2010 11:48:52 Paul Rogers wrote:
  mawk: scripts/gen-sorted.awk: line 19: regular expression compile failed
  (bad class -- [], [^] or [)
  /[^
  mawk: scripts/gen-sorted.awk: line 19: syntax error at or near ]
  mawk: scripts/gen-sorted.awk: line 19: runaway regular expression /, ,

 I've never used mawk, so I'm not familiar how similar it may be to gawk,
 but gawk is what the Host System Requirements specify.

mawk isn't all that compatible with original AKW awk. Yes, I'm still using my 
1988 edition of their AWK programming language book.


-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


live and learn

2010-06-08 Thread piper.guy1
Hi,

Started reading and doing what the book says (6.6). Didn't take too
long before I got myself into trouble. :-(

In  Host system Requirements, the instructions explicitly wants
'/bin/sh' to be pointing to bash. Mine was pointing to dash. So I
endeavoured to change it by deleting the symlink and then create
another symlink to point to bash. However, being a naive newbie all
hell broke loose when I deleted the symlink, and everything was
misbehaving. So, before I realized what I had done I logged out
rebooted and then couldn't log back in anymore.

Sooo...before I do something else that I'm not suppose to do, I
thought I'd get advise first. My thinking is that I need to get a
Linux rescue or recovery CD, mount the file system on the hard drive,
and then add a symlink to bash. Make sense or is there an easier way?

Any recommendations on a rescue disk?

One more thing. Seeing that this is a very risky thing to be advising
in LFS 6.6, can I suggest that the authour(s) add some caveats around
this instruction?

thanx
/carl h.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Bruce Dubbs
piper.guy1 wrote:
 Hi,
 
 Started reading and doing what the book says (6.6). Didn't take too
 long before I got myself into trouble. :-(
 
 In  Host system Requirements, the instructions explicitly wants
 '/bin/sh' to be pointing to bash. Mine was pointing to dash. So I
 endeavoured to change it by deleting the symlink and then create
 another symlink to point to bash. However, being a naive newbie all
 hell broke loose when I deleted the symlink, and everything was
 misbehaving. So, before I realized what I had done I logged out
 rebooted and then couldn't log back in anymore.

Yes that's a problem.  It's an opportunity to learn.  The correct 
command is:

ln -sfv bash /bin/sh

The options are
-s symbolic link
-f remove existing destination file
-v verbose

 Sooo...before I do something else that I'm not suppose to do, I
 thought I'd get advise first. My thinking is that I need to get a
 Linux rescue or recovery CD, mount the file system on the hard drive,
 and then add a symlink to bash. Make sense or is there an easier way?
 
 Any recommendations on a rescue disk?

Any disk that boots to Linux.  Mount the old partition and adjust the 
path in the ln command for the mount point.  For example:

# Your installed root partition is /dev/sda2
mount /dev/sda2 /mnt
ln -sfv bash /mnt/bin/sh
umount /mnt

 One more thing. Seeing that this is a very risky thing to be advising
 in LFS 6.6, can I suggest that the authour(s) add some caveats around
 this instruction?

LFS is not intended to teach basic Unix/Linux commands.

   -- bruce

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Ken Moffat
On 8 June 2010 21:08, piper.guy1 piper.g...@gmail.com wrote:

 Sooo...before I do something else that I'm not suppose to do, I
 thought I'd get advise first. My thinking is that I need to get a
 Linux rescue or recovery CD, mount the file system on the hard drive,
 and then add a symlink to bash. Make sense or is there an easier way?

 If you have your install CD, or probably any 'Live' CD, that
should be adequate to do this.  If not, I like systemrescuecd
[ http://www.sysresccd.org/ for details ] - download from
http://sourceforge.net/projects/systemrescuecd/

 I don't see any obvious alternative way of fixing your broken
host's /bin/sh.

ĸen
-- 
After tragedy, and farce, OMG poneys!
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Mike McCarty
piper.guy1 wrote:
 Hi,
 
 Started reading and doing what the book says (6.6). Didn't take too
 long before I got myself into trouble. :-(

Hee hee! Aren't we having fun! Before starting in on something
like this, be sure your backup and recovery procedure works well.

So, join the explicitly non exclusive club of those who have
porked their systems. One time when I was building LFS using the
alongside hint, I decided to start over, and after exiting the
chroot environment, but with the chroot environment mounts still in
place, as root, I

# cd LFS/6.3
# rm -rf build

and deleted /dev from my host system! No discs, no printers, no
terminals, etc. I rebooted with a Knoppix disc, let it populate
/dev, and then mounted my hard drive, and copied (yes copied
using cp) /dev onto my hard drive. That got my system up enough
to find out how /dev got built on my distro from a helpful
distro e-mail support group, and get it back again. No udev on
this machine, so it was definitely a little adventure.

 In  Host system Requirements, the instructions explicitly wants
 '/bin/sh' to be pointing to bash. Mine was pointing to dash. So I
 endeavoured to change it by deleting the symlink and then create
 another symlink to point to bash. However, being a naive newbie all
 hell broke loose when I deleted the symlink, and everything was
 misbehaving. So, before I realized what I had done I logged out
 rebooted and then couldn't log back in anymore.

Yeah, deleting the link without changing your /etc/passwd entry
to point to a valid shell would do that.

 Sooo...before I do something else that I'm not suppose to do, I
 thought I'd get advise first. My thinking is that I need to get a
 Linux rescue or recovery CD, mount the file system on the hard drive,
 and then add a symlink to bash. Make sense or is there an easier way?

That seems like the most obvious way to put the system back the
way it was. If you want to get the system more prepared for
the future, you could change the entry in /etc/passwd for your
login to point to /bin/dash or whatever for all users you actually
need to use, like root, yourself, and lfs or whoever. You could
then install /bin/bash and make the symlink point to that.

Another way would be to put in the symlink to /bin/dash, build
and install /bin/bash, and then repoint the symlink. Then try
logging out and back in, and see if you get some traction.

This can be done with another login still active, so you can
do some test, without porking your machine, having another
login to put things back.

 Any recommendations on a rescue disk?

I like Knoppix Vers 5.x So far, I'm not so impressed with Knoppix
Vers 6. Kanotix is another which is pretty good. I've also used
sysrescuecd, which has another set of tools. Almost anything which
can boot, recognize your disc, and make a symlink is enough. That'll
be any LiveCD version of Linux. You can have a look here

http://www.livecdlist.com/

and find one which suits your fancy. I like Puppy Linux for some stuff.
Feather Linux is pretty good, though I don't like it as much. I
like DSL a lot, and it should be capable of doing what you want.
The small distros like that have the advantage of not taking so long
to download. I've run DSL on an AMD 586 (486 class machine) with
only 16Meg of RAM, and no capability to boot from a CD-ROM, by using
SMB (smart boot manager) on a floppy.

So, nearly anything can get DSL up and running. It's a nice lean system.

 One more thing. Seeing that this is a very risky thing to be advising
 in LFS 6.6, can I suggest that the authour(s) add some caveats around
 this instruction?

Hmm. LFS is not for newbies. It would be difficult to put in
explicit enough instructions for a newbie to follow, without
making the instructions somewhat distro dependent. It's not
my call, anyway, since I'm just another LFS booster, not on
the support team.

Besides, porking your main machine to the point where it won't
boot, and figuring out how to get it back is half the fun, isn't
it? :-)

Mike
-- 
p=p=%c%s%c;main(){printf(p,34,p,34);};main(){printf(p,34,p,34);}
Oppose globalization and One World Governments like the UN.
This message made from 100% recycled bits.
You have found the bank of Larn.
I speak only for myself, and I am unanimous in that!
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Andrew Benton
On 08/06/10 21:54, Mike McCarty wrote:
 piper.guy1 wrote:
 Sooo...before I do something else that I'm not suppose to do, I
 thought I'd get advise first. My thinking is that I need to get a
 Linux rescue or recovery CD, mount the file system on the hard drive,
 and then add a symlink to bash. Make sense or is there an easier way?

 That seems like the most obvious way to put the system back the
 way it was. If you want to get the system more prepared for
 the future, you could change the entry in /etc/passwd for your
 login to point to /bin/dash or whatever for all users you actually
 need to use, like root, yourself, and lfs or whoever.

Safer than editing /etc/passwd by hand is to use the command usermod 
(read man usermod). Eg (as root)
usermod -s /bin/bash $USERNAME

Andy
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread linux fan
I haven't read where piper.guy confirmed that bash is installed or
that if bash is not installed, that changing the link to point to bash
won't help.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Bruce Dubbs
linux fan wrote:
 I haven't read where piper.guy confirmed that bash is installed or
 that if bash is not installed, that changing the link to point to bash
 won't help.

I don't know of a distro that doesn't install bash by default unless you 
are using tomsrtbt.

   -- Bruce

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: HSR's

2010-06-08 Thread Paul Rogers
 [ $(ls  /lib/libc-*.so \
  | sed 's/[.-]/ /g' \ awk '{print ($23  $34) ? foo : bar}') ==
  | foo ] 
  sed -i '/k prot/agcc_cv_libc_provides_ssp=yes' ../gcc-
  4.5.0/gcc/configure

 Please pardon me being silly.

I think you'd've LOVED APL!

This is better than one sed to insert no- in nscd's Makefile, then
rerunning the glibc build after gcc?  If and when a workaround is
needed.  Guess I'm old school. ;-)

 I understand your concern, but armored-up is really not necessary.

Not when I pull the plug, it's not!  ;-)  (Old school, again.)

 In order to make any type of connection to the new system, a process
 must be listening to a port.  There are no such processes in lfs.  The
 ping of localhost is not technically a TCP/IP process.  It never goes
 on the wire.

Certainly.  At some point in further building it may happen that there
is a running network before it's ready to meet the world.  Better, in
general, to build standalone until fully armored.  Start that way and
it's easy to stay that way through BLFS installation.  I built my LFS-
4.1 off a RHL-6.1 system.  They start the network, THEN they start the
firewall.  People make mistakes like this all the time.  It's a PITA to
get to this box's NIC connector, seemed like runlevel 2 was easier.

 After boot, the telnet, ftp, and some other clients are available, but
 we specifically --disable-servers in inetutils.

True, and I took the extra step of disabling the r* builds.

  I've never used mawk, so I'm not familiar how similar it may be to
  gawk, but gawk is what the Host System Requirements specify.

 mawk isn't all that compatible with original AKW awk.

After all I've been through, and put you all through, I'd BETTER be one
that notes gawk is required, eh?  ;-)

 In  Host system Requirements, the instructions explicitly wants
 '/bin/sh' to be pointing to bash. Mine was pointing to dash. So I
 endeavoured to change it by deleting the symlink and then create
 another symlink to point to bash. However, being a naive newbie all

You can minimize the interval with ln -sf bash /bin/sh.  Then it
stomps on the old link to dash and there's no appreciable interval when
there's no /bin/sh--but it's still not to be advised when it's a shell
something in your tty branch might have run you're messing with!

 hell broke loose when I deleted the symlink, and everything was
 misbehaving. So, before I realized what I had done I logged out
 rebooted and then couldn't log back in anymore.

Betcha don't do that nomore!  ;-)


 Sooo...before I do something else that I'm not suppose to do, I
 thought I'd get advise first. My thinking is that I need to get a
 Linux rescue or recovery CD, mount the file system on the hard drive,
 and then add a symlink to bash. Make sense or is there an easier way?

 Any recommendations on a rescue disk?

What have you got?  Tom's root boot (RTBT) runs on a floppy.  Knoppix?
If you don't have a Knoppix LiveCD, you should.  Virtually any LiveCD
should do.
-- 
Paul Rogers
paulgrog...@fastmail.fm
http://www.xprt.net/~pgrogers/
Rogers' Second Law: Everything you do communicates.
(I do not personally endorse any additions after this line. TANSTAAFL :-)



-- 
http://www.fastmail.fm - The way an email service should be

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Bruce Dubbs
Mike McCarty wrote:

 # cd LFS/6.3
 # rm -rf build
 
 and deleted /dev from my host system! No discs, no printers, no
 terminals, etc. I rebooted with a Knoppix disc, let it populate
 /dev, and then mounted my hard drive, and copied (yes copied
 using cp) /dev onto my hard drive. 

I don't think that would not be the case today since udev mounts a 
tempfs on top of /dev and populates it upon boot.  See 6.2.2. Mounting 
and Populating /dev.  At one time, what you did would have been needed.

-- Bruce
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Bruce Dubbs
Mike McCarty wrote:

 Yeah, deleting the link without changing your /etc/passwd entry
 to point to a valid shell would do that.

Changing the /etc/password file won't do much.  The bootscripts need 
/bin/sh.

   -- Bruce
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread piper.guy1
On Tue, Jun 8, 2010 at 5:50 PM, linux fan linuxscra...@gmail.com wrote:
 I haven't read where piper.guy confirmed that bash is installed or
 that if bash is not installed, that changing the link to point to bash
 won't help.
 --
 http://linuxfromscratch.org/mailman/listinfo/lfs-support
 FAQ: http://www.linuxfromscratch.org/lfs/faq.html
 Unsubscribe: See the above information page


Oh yes, it's there. I did confirm that bash was there before my calamity.

/carl h.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: HSR's

2010-06-08 Thread Neal Murphy
On Tuesday 08 June 2010 19:04:21 Paul Rogers wrote:
 You can minimize the interval with ln -sf bash /bin/sh.  Then it
 stomps on the old link to dash and there's no appreciable interval when
 there's no /bin/sh--but it's still not to be advised when it's a shell
 something in your tty branch might have run you're messing with!

This is somewhat true. The running shell will not be affected. Subsequent 
attempts to run that shell will fail.

It's been a long time since shell scripts were 'cached' in the filesystem such 
that editting a script would cause the running script to fail. And it's 
likely been nearly as long since an executing binary has been 'cached' on its 
filesystem.

Linux deletes the file from the FS, but keeps it available to all processes 
that have it open. It is deleted and forgotten when the last open FD is 
closed. So if you are running /bin/bash and you delete /bin/bash, your shell 
will continue to run until it closes the FD that has /bin/bash opened. Put 
differently, it is deleted from the FS directory and from the in-cache 
directory, but it cannot be deleted completely until the last process closes 
the FD. In a way, it is an orphan during the interim; it cannot be opened 
anew, but it can continue to be processed until the last FD that has it open 
is closed.

So, in the case that spawned this thread, the used could have continued to use 
his shell, albeit vey carefully and judiciously, until he exitted that shell. 
Even if he performed an 'rm -rf /', his shell would continue to run and he 
would continue to be able to use shell built-ins until he exitted that shell. 
At that point, only the root directory, '.' and '..' would be accessible.

Confused? Read up on tmpfs and how initramfs works. Hint: they both work with 
*no* filesystem structure, just directories and files with no backing store. 
They're one step removed from a RAM disk with a file structure layered on 
top. Were I to agree with software patents, this might be one of them. 
Another hint: it is what allows LiveCD Linux systems to run completely in 
RAM. Also read up on how file access works. When you open a file, you do not 
open the file on disk (normally). You ask the system to open the file for 
you. It creates an entry in the cache directory for that file, pages the file 
into memory over time, and allows you to access the file. When you close the 
file, it stays in cache until something else needs the memory more urgently.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Neal Murphy
On Tuesday 08 June 2010 16:54:52 Mike McCarty wrote:
 piper.guy1 wrote:
  One more thing. Seeing that this is a very risky thing to be advising
  in LFS 6.6, can I suggest that the authour(s) add some caveats around
  this instruction?

The best way to do LFS is to pretend you are the computer, executing each 
command and understanding what each command does. In short time, you'll come 
to recognize what is happening and learn to pause before you hit the ENTER 
key.

Been there, done that. Hmmm. May I produce a t-shirt that proclaims, Member 
of the 'I hosed my Linux system building LFS!' club ??


 Besides, porking your main machine to the point where it won't
 boot, and figuring out how to get it back is half the fun, isn't
 it? :-)

It's fun the first couple times. :) Then it just becomes tedious and a pain to 
figure out how to avoid it in the future. :D

In a way, LFS is instructionary (as intended). If you do *exactly* what the 
book says, the probability is high that you will succeed and not hose your 
host system. I started playing with UNIX in 1986, and Linux in the 
mid-nineties. And just a couple weeks ago, I overwrote a disk that contained 
half of a couple striped MD filesystems. Lost nearly 10 years of pics and 
history. Another time, while redesigning the Smoothwall build system, I 
overwrote large bits of my host system because the build system did what I 
*told* it to do, not what I *wanted* it to do. Sigh. I *meant* to copy an 
external drive's image to a partition, *not* the whole drive.

So if all you did was wipe out a link to a shell, you haven't tried hard 
enough. :) Almost any Linux distro that has a rescue mode (even Debian's 
netinstall CD will work, and its much quicker) will allow you to boot into a 
usable Linux and repair such minor damage.
  - boot the live or rescue system
  - don't use your host's FS as root
  - mount your host's root FS and/or /usr FS, as needed
  - find what you hosed and any alternatives
  - create a symlink from that which you lost to an alternative
For example, if you deleted the symlink to dash, you can create a new link to 
dash. If you wiped out dash itself, you can create a symlink to just about 
anything that will act as a shell. Tclsh would do in a pinch; even perl or 
php would work.

At the worst, you might have to find and download the bash/dash/csh/tcsh 
package, learn to unarchive it, and replace only what you deleted. You could 
get lucky and find the package cached in a package archive area, as you'd 
find in at least Debian or Ubuntu (an ancient African word meaning can't 
install Debian).

And, yes, I have done 'rm -rf *' when in the root directory on my old ATT 
UNIXPC. I've since learned to be more careful. But, clearly, not careful 
enough. :) 

Just remember, it's only a computer. It can be restored to proper operating 
condition. In time, you'll learn to keep your personal data on a separate 
filesystem. You'll learn to pause before hitting ENTER. And in time you'll 
wonder why you stuck with Winders or Mac so long.

'97-02, I used BeOS as my primary system. For a short time, I used Windows 
after, until Debian Etch was release. I've been using Linux as my primary 
system ever since.

As Mike says, LFS is not for newbies. Though I might allow that it is not for 
newbies who have only one computer. Keep a computer, any computer, handy for 
internet access to search for the mistakes you make and how others have 
recovered. At least technically, we humans learn from our mistakes and are 
usually willing to help teach others to avoid and/or recover from theirs. 
Often you'll get a respone that details how to recover. Other times, you get 
a response like, There, there. This, too, shall pass.

So welcome to the world of virtual reality, where the all that exists are 
meaningless bits. It is all virtual; none of it is tangible. It is there to 
be moulded to our own individual desires.

In the future, pay close attention to *each* step of LFS. And be sure to 
follow each step *exactly*.

[Fest3er steps off his soapbox and puts it away.]

A possible future enhancement to 'the book' might be to incorporate checkboxes 
that a newbie would check off as she performs each step. Extra work? Yes. But 
worth it to make each step clearer? Yes again.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Neal Murphy
On Tuesday 08 June 2010 18:57:21 Bruce Dubbs wrote:
 Mike McCarty wrote:
  # cd LFS/6.3
  # rm -rf build
 
  and deleted /dev from my host system! No discs, no printers, no
  terminals, etc. I rebooted with a Knoppix disc, let it populate
  /dev, and then mounted my hard drive, and copied (yes copied
  using cp) /dev onto my hard drive.

 I don't think that would not be the case today since udev mounts a
 tempfs on top of /dev and populates it upon boot.  See 6.2.2. Mounting
 and Populating /dev.  At one time, what you did would have been needed.

But later, Mike says his system does not have udev.

If Mike had known the 'basic' /dev entries needed, he probably could have used 
mknod to create them. He could have booted some Linux in a virtual system, 
archived /dev, copied it to the system he crippled and unarchived it.

To quote an old SF TV show, Many such journeys are possible. :) :)
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Bruce Dubbs
Neal Murphy wrote:

 I started playing with UNIX in 1986, and Linux in the 
 mid-nineties. And just a couple weeks ago, I overwrote a disk that contained 
 half of a couple striped MD filesystems. Lost nearly 10 years of pics and 
 history.

No backups?  How is this different (in effect) from a failed disk drive.

   -- Bruce

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread Neal Murphy
On Tuesday 08 June 2010 20:05:46 Bruce Dubbs wrote:
 Neal Murphy wrote:
  I started playing with UNIX in 1986, and Linux in the
  mid-nineties. And just a couple weeks ago, I overwrote a disk that
  contained half of a couple striped MD filesystems. Lost nearly 10 years
  of pics and history.

 No backups?  How is this different (in effect) from a failed disk drive.

It differs in that I keep an eye on my hard drives. When they start to show 
signs of old age and failure, I buy a replacement and move everything to the 
new drive. (Euthenasia doesn't apply to hard drives.)

I've been close to a drive failure (an 'older' WD 30GB drive), but heard it 
struggling to read and decided I should buy a replacement. And back when 1TB 
drives reached $80US, I bought two Hitachi SATA 3s to replace the perfectly 
functional and problem-free 400GB Apple SATA 1.5s I'd bought a few years 
years earlier; I needed more disk space. Alas, wiping out data is *not* the 
preferred method of acquiring more disk space. :( Of course, it didn't help 
that my ASUS dual dual-core Opteron mboard on-board power supply capacitors 
gave up their ghosts; that's when I bought the new mboard and a quad PhII 965 
and 8GB RAM. (I truly *despise* waiting for Linux distribs to compile.)

But you are right. I had no backups and no excuses. I have an empty 400GB 
drive that would have held most of that data. And there's no reason I could 
not have saved all the pics to DVDs. I didn't. I lost. Oh, well. No one died, 
and no critters or humans were harmed, so no foul. :) Too bad I didn't wipe 
out my ripped CDs. I could've re-ripped them. Sigh.
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page


Re: live and learn

2010-06-08 Thread littlebat
On Tue, 8 Jun 2010 16:08:18 -0400

 In  Host system Requirements, the instructions explicitly wants
 '/bin/sh' to be pointing to bash. Mine was pointing to dash. 

under Ubuntu, try sudo dpkg-reconfigure dash.

 Any recommendations on a rescue disk?

CDlinux. ( http://cdlinux.info/ )

PS: try virtual machine as your LFS building host. It will keep you real 
physical machine safe.

-- 
littlebat dashing.m...@gmail.com
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page