Linux-Misc Digest #456, Volume #24               Sat, 13 May 00 23:13:03 EDT

Contents:
  Re: Help->Colourised Login (William Adderholdt)
  Re: Module loading (Duane)
  Re: naive question on programming Linux applications (Steve)
  Re: Reinstallation too slow (Steve)
  Having trouble installing 2 network cards ([EMAIL PROTECTED])
  Re: How to protect Linux against power interruptions?? (Bob Tennent)
  getty problem (Brenden McNeil)
  sysadmin book ([EMAIL PROTECTED])
  Linux on Sun Sparc (Pjtg0707)
  Re: getty problem (Munge)
  Can't unmount - device busy (Ric)
  Re: How to protect Linux against power interruptions?? (Joey Wetherington)
  Thrashing drive (John Scudder)
  Re: Can't unmount - device busy (Paul Lew)
  Re: Thrashing drive (Christopher Browne)
  Re: "From" in elm and mutt (Gary Dolan)

----------------------------------------------------------------------------

Crossposted-To: comp.os.linux.setup
Reply-To: William Adderholdt <[EMAIL PROTECTED]>
Subject: Re: Help->Colourised Login
From: [EMAIL PROTECTED] (William Adderholdt)
Date: Sat, 13 May 2000 22:29:10 GMT

[comp.os.linux.advocacy removed]

In article <8fij96$dp1$[EMAIL PROTECTED]>, Jackie <[EMAIL PROTECTED]> wrote:
> Hi there, I know BLUE="$ESC[44;37m" and NORMAL="$ESC[40;37m". But how about
> the others, such as read, yellow....? Pls point me to the right doc.
> Thx in adv  - Jackie mailto:[EMAIL PROTECTED]

The doc you want is the console_codes(4) man page.  There you would
find, for example:

       30    set black foreground
       31    set red foreground
       32    set green foreground
       33    set brown foreground
       34    set blue foreground
       35    set magenta foreground
       36    set cyan foreground
       37    set white foreground
       38    set underscore on, set default foreground color
       39    set underscore off, set default foreground color
       40    set black background
       41    set red background
       42    set green background
       43    set brown background
       44    set blue background
       45    set magenta background
       46    set cyan background
       47    set white background
       49    set default background color

Hope this helps!

William Adderholdt

------------------------------

From: Duane <[EMAIL PROTECTED]>
Subject: Re: Module loading
Date: Sat, 13 May 2000 22:20:03 GMT

In article <tEbT4.1091$[EMAIL PROTECTED]>,
  [EMAIL PROTECTED] wrote:
> In <8fh43n$3t4$[EMAIL PROTECTED]>, "Florian E.J. Fruth"
<[EMAIL PROTECTED]> writes:
> >did u compile the kernel with the support for automatic module
loading ?
> >fejf
> Yes.
> I even did a complete re-format and re-install and still can't work it
out.
>
> I'm beginning to wonder whether there's something wrong with Mandrake.
> After re-installing, and not fiddling with *any* source code, I tried
> to re-build the kernel making sure all the right options for me were
> configured correctly.  I did:
> make dep
> make clean
> make bzImage

Oops. Don't know if it will fix the problem, but normally you would
do a make clean first, and then make depend.

--
My real email is akamail.com@dclark (or something like that).


Sent via Deja.com http://www.deja.com/
Before you buy.

------------------------------

From: [EMAIL PROTECTED] (Steve)
Subject: Re: naive question on programming Linux applications
Reply-To: [EMAIL PROTECTED]
Date: 13 May 2000 23:48:24 GMT

On Sat, 13 May 2000 14:11:00 GMT, [EMAIL PROTECTED] wrote:
>
>
>I'm wondering what one needs to learn to be able to program applications
>for Linux. I'm not very experienced as a programmer, but I can do all the
>web-related programming I need (JS, Perl and PHP) and I do have the
>opportunity to take some classes in the next couple of years. What should
>I learn? C++? More advanced data-structures classes?
>
>Are there any good books on this subject?

I think this is very much a matter of taste, ie, what would you like to learn.
This environment (computers/IT in general), are changing so quickly no one
knows what the important (or even useful) skills will be in two years.  

Find something you like and push the boundries.  
Good luck.

-- 
Cheers
Steve              email mailto:[EMAIL PROTECTED]

%HAV-A-NICEDAY Error not enough coffee  0 pps. 

web http://www.ndirect.co.uk/~sjlen/

or  http://start.at/zero-pps

 10:39pm  up 17 days, 40 min,  3 users,  load average: 1.31, 1.23, 1.17

------------------------------

From: [EMAIL PROTECTED] (Steve)
Subject: Re: Reinstallation too slow
Reply-To: [EMAIL PROTECTED]
Date: 13 May 2000 23:48:27 GMT

On Sat, 13 May 2000 14:19:42 GMT, SilentNight wrote:
>Hi all,
>
>I am a newbie to Linux.  I tried the Corel Linux, but after
>the first installation, it seems very slow to boot up.
>
>So, I decided to reinstall.  But both floppy and cd-rom setup
>has no response for a very long time.
>
>Even if I want to re-partition; i.e., resize, I have no chance.
>
>Using other boot disk from RedHat and Turbo Linux have
>the same phenominon.
>
>I think I am doing something wrong; but
>
>What is wrong with this ?

It could be that your HD's on the way out.  But mixing and matching
on install doesn't sound like a wise thing to do unless you're sure
that you really know what you're doing and what the consequences will
be.  

-- 
Cheers
Steve              email mailto:[EMAIL PROTECTED]

%HAV-A-NICEDAY Error not enough coffee  0 pps. 

web http://www.ndirect.co.uk/~sjlen/

or  http://start.at/zero-pps

 10:39pm  up 17 days, 40 min,  3 users,  load average: 1.31, 1.23, 1.17

------------------------------

From: [EMAIL PROTECTED]
Crossposted-To: comp.os.linux.networking,comp.os.linux.setup
Subject: Having trouble installing 2 network cards
Date: Sat, 13 May 2000 22:43:17 GMT

I'm getting ready to set my Linux box as an internet gateway for a small
network of about 5 Windows95 machines.  The first step was to try to
install a second network card into the machine and set up a "private"
internal network.  But I've run into trouble - I feel like I've ALMOST
got it right, but have missed a few steps.  Thanks to anyone who can
show me where I went wrong!

First, this is a Dell 180Mhz machine running Red Hat Linux 6.0.  It has
a DSL connection with a static IP address.  It stands in isolation from
a network of about 5 Windows95 PCs.  I'd like to add it to the network
so the other PCs can get on the internet through the Linux box.

I've decided to use a 192.168.0.x network - the Linux box will be
192.168.0.1 , and the IP's for rest of the network will go
incrementally from there.

I added a second NIC to the Linux box, which seemed to be recognized
when the machine rebooted.  I used the "netcfg" program, which added a
new line to my /etc/conf.modules file for the card.
(the output from several relevant programs and files is below)

Here are the problems:

1) After installing the second network card, I was no longer able to
get on the internet from the Linux machine!
  > ping www.yahoo.com
  ping: unknown host: www.yahoo.com
  > ping 216.32.74.51
  PING 216.32.74.51 (216.32.74.51): 56 data bytes
  ping: sendto: Network is unreachable
  ping: wrote 216.32.74.51 64 chars, ret=-1

I was able to fix this problem (with a tip I read somewhere) by running
this command as root:
  > route add gateway default

Then it worked.
  > ping www.yahoo.com
  PING www.yahoo.akadns.net (216.32.74.52): 56 data bytes
  64 bytes from 216.32.74.52: icmp_seq=0 ttl=243 time=25.4 ms
  64 bytes from 216.32.74.52: icmp_seq=1 ttl=243 time=24.3 ms
  ...

But I'm not sure why I that problem occurred (unless it simply meant
that Linux no longer knew how to reach the Internet due to the presence
of multiple NICs), or how to solve this problem in a more permanent way
other than typing in that line every time I reboot!


2) I am also unable to ping any of the machines on my "internal"
network, and they cannot ping me.  They CAN, however, ping each other.
  > ping 192.168.0.2
  PING 192.168.0.2 (192.168.0.2): 56 data bytes
  --- 192.168.0.2 ping statistics ---
  10 packets transmitted, 0 packets received, 100% packet loss

The other machines are all Windows95.  They have their IP addresses
manually specified (e.g. 192.168.0.1), subnet mask 255.255.255.0, have
their Gateway set to 192.168.0.1 and their DNS also set to 192.168.0.1
.  And they can ping each other fine, but not the Linux server.

Here's some of my settings:

=======================================================
/etc/conf.modules
     alias eth0 3c59x
     alias eth1 3c59x
(these are two similar but not identical cards)
(is there a problem since I'm NOT specifying IO/IRQ info?)

=======================================================
OUTPUT FROM ifconfig:
lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Bcast:127.255.255.255  Mask:255.0.0.0
          UP BROADCAST LOOPBACK RUNNING  MTU:3584  Metric:1
          RX packets:160 errors:0 dropped:0 overruns:0 frame:0
          TX packets:160 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0

eth0      Link encap:Ethernet  HWaddr 00:60:97:BE:1E:B2
          inet addr:64.40.68.250  Bcast:64.40.68.255
Mask:255.255.255.252
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:2071 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2482 errors:0 dropped:0 overruns:0 carrier:0
          collisions:4
          Interrupt:9 Base address:0xff00

eth1      Link encap:Ethernet  HWaddr 00:A0:24:C6:2C:05
          inet addr:192.168.0.1  Bcast:192.168.0.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:47 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0
          Interrupt:10 Base address:0xff80

=======================================================
OUTPUT FROM netstat -r:
Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt
Iface
64.40.68.248    *               255.255.255.252 U      1500 0          0
eth0
192.168.0.0     *               255.255.255.0   U      1500 0          0
eth1
127.0.0.0       *               255.0.0.0       U      3584 0          0
lo

default         *               0.0.0.0         U      1500 0          0
eth0
#### Note that the last line only appears after
#### I manually run "route add default eth0"

=======================================================
/etc/sysconfig/network
NETWORKING=yes
FORWARD_IPV4=yes
HOSTNAME=grbc.vor.org
DOMAINNAME=vor.org
# GATEWAY=
GATEWAY=
GATEWAYDEV=eth0
NISDOMAIN=""
IPX="no"
IPXINTERNALNETNUM="0"
IPXINTERNALNODENUM="0"
IPXAUTOPRIMARY="on"
IPXAUTOFRAME="on"

=======================================================
/etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
USERCTL=no
ONBOOT="yes"
BOOTPROTO="none"
BROADCAST=64.40.68.255
NETWORK=64.40.68.248
NETMASK="255.255.255.252"
IPADDR="64.40.68.250"
IPXNETNUM_802_2=""
IPXPRIMARY_802_2="no"
IPXACTIVE_802_2="no"
IPXNETNUM_802_3=""
IPXPRIMARY_802_3="no"
IPXACTIVE_802_3="no"
IPXNETNUM_ETHERII=""
IPXPRIMARY_ETHERII="no"
IPXACTIVE_ETHERII="no"
IPXNETNUM_SNAP=""
IPXPRIMARY_SNAP="no"
IPXACTIVE_SNAP="no"

=======================================================
/etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth1"
USERCTL=yes
ONBOOT="yes"
BOOTPROTO="none"
BROADCAST=192.168.0.255
NETWORK=192.168.0.0
NETMASK="255.255.255.0"
IPADDR="192.168.0.1"
IPXNETNUM_802_2=""
IPXPRIMARY_802_2="no"
IPXACTIVE_802_2="no"
IPXNETNUM_802_3=""
IPXPRIMARY_802_3="no"
IPXACTIVE_802_3="no"
IPXNETNUM_ETHERII=""
IPXPRIMARY_ETHERII="no"
IPXACTIVE_ETHERII="no"
IPXNETNUM_SNAP=""
IPXPRIMARY_SNAP="no"
IPXACTIVE_SNAP="no"

===============================

Again, thanks to anyone who can help!


Sent via Deja.com http://www.deja.com/
Before you buy.

------------------------------

From: [EMAIL PROTECTED] (Bob Tennent)
Crossposted-To: comp.os.linux.setup
Subject: Re: How to protect Linux against power interruptions??
Date: 13 May 2000 23:09:40 GMT
Reply-To: [EMAIL PROTECTED]

On Sat, 13 May 2000 21:18:26 GMT, Allen Unrau wrote:
 >Is there a way to protect Linux against the effects of power interruptions
 >(power failure, maid trips over plug, etc.) 
 >
 >Is there a program that periodically syncs the disks? How about running
 >without swap? Any other ideas (other than providing a UPS)?

A small UPS will only cost about $100.  It's worth it.

Bob T.

------------------------------

From: Brenden McNeil <[EMAIL PROTECTED]>
Subject: getty problem
Date: Sun, 14 May 2000 00:14:55 GMT

I have a good ol' VT100 terminal hooked up to my machine with the
proper cable.  I put getty in /etc/inittab.  Among other syntaxes,
right now I have:

S1:2345:respawn:/sbin/getty ttyS0 vt100

in it.  No matter what syntax I use, I get a message on the monitor
that says something to the efect of process S1 is respawning too fast,
waiting 5 minutes.

How do I fix this?  What is the correct syntax of the command?

(I'm running redhat 6)

Thanks for your help.


Sent via Deja.com http://www.deja.com/
Before you buy.

------------------------------

From: [EMAIL PROTECTED]
Subject: sysadmin book
Date: Sun, 14 May 2000 01:10:55 GMT

Hi,

Is there a comprehensive book on linux/unix system administration that
would explain the tasks of a system administrator from the time the
system is installed through adding new users/terminals? I need a book
that explains the why's of systems administration not just the what's
and the how's.

If this is the wrong forum to ask, where should I ask?

Thanks in advance

MTOV


Sent via Deja.com http://www.deja.com/
Before you buy.

------------------------------

From: [EMAIL PROTECTED] (Pjtg0707)
Subject: Linux on Sun Sparc
Reply-To: [EMAIL PROTECTED]
Date: Sun, 14 May 2000 01:23:55 GMT

Hi,

I've come across some SUn Sparc2 as surplus, and I am wondering if anyone 
here are running Linux on Sparcs. How id the performance and what are the 
hardware requirements?





------------------------------

From: Munge <[EMAIL PROTECTED]>
Subject: Re: getty problem
Date: 14 May 2000 01:58:34 GMT

Brenden McNeil <[EMAIL PROTECTED]> wrote:
: I have a good ol' VT100 terminal hooked up to my machine with the
: proper cable.  I put getty in /etc/inittab.  Among other syntaxes,
: right now I have:

: S1:2345:respawn:/sbin/getty ttyS0 vt100


It should look like this:

S1:2345:respawn:/sbin/getty ttyS1 DT19200

and you  should have a corresponding entry in /etc/gettydefs
like this:

DT19200# B19200 CS8 CLOCAL # B19200 SANE -ISTRIP CLOCAL #@S login: #DT19200

: How do I fix this?  What is the correct syntax of the command?

Read the instructions for getty very carefully. Man 1 "getty" and
man 5 "gettydefs". Make sure you have all the necessary serial line
settings before doing anything, i.e speed, stop bits, parity. If
you don't have them, start up minicom as root and use the serial port
for the terminal. Experiment with line settings until you get characters
appearing correctly.



------------------------------

From: Ric <[EMAIL PROTECTED]>
Subject: Can't unmount - device busy
Date: Sun, 14 May 2000 03:02:49 +0100

I did something which, at the time, seemed a fairly reasonable
strategy, but which has come back to haunt me.  

I decided to move some of the partitions on my RH6.2 system around to
get more space.  To do this I simply created new partitions, created a
file system, mounted at a new mount point and copied the contents of
the old mount point to the new one, then changed /etc/fstab and
reboorted.  Before removing the old partitions I tested the system and
everything seemed ok.  Now, however, a problem has arisen. One of the
partitions that I moved contained /usr and when I try to shutdown the
system hangs while trying to unmount the filesystem.  The specific
message is:

        Unmounting file systems umount2: Device or resource busy
        umount: /usr: device is busy

The system then does nothing.  I have tried the three-finger salute,
but end up in the same place.

I suspect that when I copied the directories over there is a counter
somewhere that contains the number of users of the
filesystem/directory/something which was duly copied to the new
partition. When I did the clean shutdown on the old partition the
'number of users' count was obviously decremented, but not for the
copy of the paritition.  Now, of course, there is one more in the
count than real users in the new partition.  I have tried using
debugfs and ext2ed to look for something that could contain this
information, but I have drawn a blank. In order to reboot the system I
have to power off, which causes a fsck on startup.  I have tried
booting with the partitions offline and running fsck, which reports no
errors. I can then mount the device and immediately try to unmount it,
without accessing it, and get the same device busy message.

Please can someone tell me where this counter is being held and how I
can reset it?  

Thank you

------------------------------

Crossposted-To: comp.os.linux.setup
Subject: Re: How to protect Linux against power interruptions??
From: [EMAIL PROTECTED] (Joey Wetherington)
Date: 13 May 2000 21:03:42 -0500

In article <[EMAIL PROTECTED]>,
Bob Tennent <[EMAIL PROTECTED]> wrote:
>On Sat, 13 May 2000 21:18:26 GMT, Allen Unrau wrote:
> >Is there a way to protect Linux against the effects of power interruptions
> >(power failure, maid trips over plug, etc.) 
> >
> >Is there a program that periodically syncs the disks? How about running
> >without swap? Any other ideas (other than providing a UPS)?
>
>A small UPS will only cost about $100.  It's worth it.
>
>Bob T.

Also, if at all possible, remove, disable or hide the on/off & reset
switches. Here's the gist of a conversation I had Friday:

"Why is the uptime only three hours?"
"I soft booted the machine."
"Did you press keys on the keyboard to do that?"
"No. I pressed the reset button."
"That's a hard boot. If you keep doing that, you're going to scramble
the file system."
"Oh."
Did it fix the problem?"
"No."
"I'm not surprised. Stop doing that."

But I can hardly blame them. It's like that hammer and nail thing:
When you're using Microsoft in your office and at your home, every
computer looks like something that should be bashed with a 32-ounce
hammer.




====== Posted via Newsfeeds.Com, Uncensored Usenet News ======
http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
=======  Over 80,000 Newsgroups = 16 Different Servers! ======

------------------------------

From: John Scudder <[EMAIL PROTECTED]>
Subject: Thrashing drive
Date: Sat, 13 May 2000 22:44:13 -0500

At least once an evening while I am quiety reading mail, my hard drive
starts thrashing around for no apparent reason for several minutes or
more.  Then it stops on its own and is quiet for the rest of the
evening.  Why is it doing this?  Could it be related to my swap
file?

I have SuSE 6.3,  64 M ram, 128 M swap file, and a 10 G SCSI hard drive.

Thanks,

John


------------------------------

From: [EMAIL PROTECTED] (Paul Lew)
Subject: Re: Can't unmount - device busy
Date: Sun, 14 May 2000 02:42:37 GMT

You need to umount whatever were mounted in /usr first; like umount
stuff bottom-up.  I had about the same problem when upgrading to a
larger harddrive today.

On Sun, 14 May 2000 03:02:49 +0100, Ric <[EMAIL PROTECTED]> wrote:
>I did something which, at the time, seemed a fairly reasonable
>strategy, but which has come back to haunt me.  
>
>I decided to move some of the partitions on my RH6.2 system around to
>get more space.  To do this I simply created new partitions, created a
>file system, mounted at a new mount point and copied the contents of
>the old mount point to the new one, then changed /etc/fstab and
>reboorted.  Before removing the old partitions I tested the system and
>everything seemed ok.  Now, however, a problem has arisen. One of the
>partitions that I moved contained /usr and when I try to shutdown the
>system hangs while trying to unmount the filesystem.  The specific
>message is:
>
>       Unmounting file systems umount2: Device or resource busy
>       umount: /usr: device is busy
>
>The system then does nothing.  I have tried the three-finger salute,
>but end up in the same place.
>
>I suspect that when I copied the directories over there is a counter
>somewhere that contains the number of users of the
>filesystem/directory/something which was duly copied to the new
>partition. When I did the clean shutdown on the old partition the
>'number of users' count was obviously decremented, but not for the
>copy of the paritition.  Now, of course, there is one more in the
>count than real users in the new partition.  I have tried using
>debugfs and ext2ed to look for something that could contain this
>information, but I have drawn a blank. In order to reboot the system I
>have to power off, which causes a fsck on startup.  I have tried
>booting with the partitions offline and running fsck, which reports no
>errors. I can then mount the device and immediately try to unmount it,
>without accessing it, and get the same device busy message.
>
>Please can someone tell me where this counter is being held and how I
>can reset it?  
>
>Thank you

------------------------------

From: [EMAIL PROTECTED] (Christopher Browne)
Subject: Re: Thrashing drive
Reply-To: [EMAIL PROTECTED]
Date: Sun, 14 May 2000 02:57:26 GMT

Centuries ago, Nostradamus foresaw a time when John Scudder would say:
>At least once an evening while I am quiety reading mail, my hard drive
>starts thrashing around for no apparent reason for several minutes or
>more.  Then it stops on its own and is quiet for the rest of the
>evening.  Why is it doing this?  Could it be related to my swap
>file?

It is entirely likely that this is a process scheduled to do some
system cleanup.  A likely "for instance" would be running a reindexing
of manual pages, rebuilding what is read when you do:
  man -k

You might look at /etc/crontab, or in directories like /etc/cron.daily,
to find details.
-- 
Why don't sheep shrink when it rains? 
[EMAIL PROTECTED] - - <http://www.ntlug.org/~cbbrowne/lsf.html>

------------------------------

From: [EMAIL PROTECTED] (Gary Dolan)
Crossposted-To: comp.os.linux.networking,comp.os.linux.setup,alt.os.linux
Subject: Re: "From" in elm and mutt
Reply-To: [EMAIL PROTECTED]
Date: Sun, 14 May 2000 02:54:12 GMT

>Quentin PHILIPPE wrote:
>
>> Hello,
>>
>> I have a problem with elm and mutt: If I send an email with them, the
>> answer address is [EMAIL PROTECTED] (easynet is my provider, and
>> quentin my user under linux). And it should be as underneath:
>> [EMAIL PROTECTED]

Why not just put
my_header From: [EMAIL PROTECTED]
my_header Reply-To: [EMAIL PROTECTED]
in your .muttrc
-- 
Gary Dolan
Debian GNU/Linux, Kernel 2.2.14

------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: [EMAIL PROTECTED]

You can send mail to the entire list (and comp.os.linux.misc) via:

    Internet: [EMAIL PROTECTED]

Linux may be obtained via one of these FTP sites:
    ftp.funet.fi                                pub/Linux
    tsx-11.mit.edu                              pub/linux
    sunsite.unc.edu                             pub/Linux

End of Linux-Misc Digest
******************************

Reply via email to