Linux-Misc Digest #621, Volume #27               Mon, 16 Apr 01 16:13:02 EDT

Contents:
  Re: READ THIS!!!Here is the technical explanation! ([EMAIL PROTECTED])
  Re: Adding disk to raid0 w/reiserfs (Emil Naepflein)
  Re: Thrashing HD (Jean-David Beyer)
  Re: process just refuses to die!!!! (Jean-David Beyer)
  Problem using mmap under Linux (works under Solaris) (Kenny McCormack)
  Re: Tizek.com is in dire need of a development team... (Nix)
  Re: Diskless boot from floppy help ("Tauno Voipio")
  Re: How to measure elapsed time? (Holland King)
  inittab question (toy)
  Re: READ THIS!!!Here is the technical explanation! (Dan Mercer)
  Re: Could Linux be used in this factory environment ? (Paul Repacholi)
  Re: Tizek.com is in dire need of a development team... ([EMAIL PROTECTED])
  Changing the paper size for PS files (* Tong *)
  Re: 4 pages per sheet, double sided (Kevin)

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

From: [EMAIL PROTECTED]
Subject: Re: READ THIS!!!Here is the technical explanation!
Date: Mon, 16 Apr 2001 17:22:57 GMT

[EMAIL PROTECTED] (Dan Mercer) writes:
> In article <[EMAIL PROTECTED]>,
> Jason <[EMAIL PROTECTED]> writes:
> > Jason wrote:
> >>
> >> If this is the wrong newsgroup, sorry.
> >> Hi, I have an important question, I'm not trying to cause trouble, but
> >> why is it that Internet Explorer  for Microsoft runs so much faster than
> >> any browser on Linux?
> > 
> > It's not. It's faster than Netscape or Mozilla for some things,
> > but is slow as a sloth compared to Konqueror and many of the other
> > borwsers out there.
> > 
> > In part, IE has going for it that portions of the browser reside in the
> > kernel instead of user space, and it uses DirectDraw for some rendering
> > (and Netscape etc don't use DRI). Also, IE uses the native widget set
> > whereas Netscape uses the poorly design Motif widget set. In comparison,

> Motif is hardly "poorly designed".  Netscape's implementation on
> Motif was very poor.  Netscape's ignorance is not Motif's fault.

Hmm...  Motif has long been famed for requiring applications to have
quite a lot of workarounds for bugs that accreted over the years.  And
of course, once there's a substantial codebase out there that
_depends_ on working around the bugs, that makes it impossible to fix
them.

<http://ecco.bsee.swin.edu.au/unix/uh/motif.html>
<http://catalog.com/hopkins/unix-haters/x-windows/disaster.html>
-- 
(concatenate 'string "cbbrowne" "@acm.org")
http://www.ntlug.org/~cbbrowne/resume.html
"If the  future navigation system [for  interactive networked services
on the NII] looks like  something from Microsoft, it will never work."
-- Chairman of Walt Disney Television & Telecommunications

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

From: [EMAIL PROTECTED] (Emil Naepflein)
Crossposted-To: comp.os.linux.setup
Subject: Re: Adding disk to raid0 w/reiserfs
Date: Mon, 16 Apr 2001 19:37:16 +0200

I just saw this old posting and would like to add some comments:

On 27 Mar 2001 19:16:58 GMT, [EMAIL PROTECTED] (bill davidsen) (bill
davidsen) wrote:

>   Reading the documentation you will see that you can not add the extra
> drives without destroying the data. The docs clearly, unambiguously and
> explicitly say this in several places.

There is a conversion described from Raid-1 to Raid-5. But backup is
recommended anyway.

>   The first thing you do when you're in a hole is stop digging. Once you
> solve the backup problem all other problems become easy. I suspect
> you're not going to believe me or any of the other people who posted
> much the same thing...

The problem is that if you really have a lot of data 100s of GB backup
becomes really expensive. I am looking for a possibility to upgrade a
Raid-7 array with further drives. I will store digital sat recordings,
which are by no means absolutely critical data to me. A loss would be
very annoying, but by no means catastrophic. I will start with 4 disks
in a Raid-5 array and may later upgrade disk by disk when the space is
becoming necessary. As each disk will be a Maxtor 80 GB, backup for all
the data would be very expensive. I am looking for a strategy to make
this upgrade possible without to much hassle.

I see two basic strategy:
1. Modification at the block level
As we know the layout of the old and new raid configuration we can copy
the blocks around to match the new configuration and then enable the
raid to reconstruct the parity. The size of the converted partitions
shouldn't change to avoid resizing filessystems which may not be able to
do so. The new space should be added at the end of the converted
partition and can be used for new partitions. 
But a crash during the modification can make all the data unusable. 

2. Split the large 80 GB disks into smaller junks of 10-20 GB partitions
This way we have multiple raid-5 on the disks and can use space on the
new disk as temporary storage and so convert the whole disk step by step
until all raid-5 partitions incorporate the new disk.

I personally would prefer the 1. solution if it does proper
checkpointing so that a crash wouldn't cause the loss of any data. But
there is currently no software available that can do this. 
So the second strategy seems to be the only feasable at the moment.

Do you have any other ideas?

Emil   

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

From: Jean-David Beyer <[EMAIL PROTECTED]>
Subject: Re: Thrashing HD
Date: Mon, 16 Apr 2001 13:57:21 -0400

"Peter T. Breuer" wrote:
> 
> John Scudder <[EMAIL PROTECTED]> wrote:
> >>
> >> This is hardly going to take more than 5 minutes. He says it goes on
> >> forever! Perhaps he should have a look with "top" to see what is
> >> running.
> 
> > My Mandrake Linux machine does exactly the same thrashing after 15 minutes..  I
> > ran 'gtop' to find the culprit and found that 'slocate' was taking a good
> > portion of my CPU time.  The trashing usually stops after 5 minutes, I have
> > learned to live with it but would like to know if I really need to have this
> > run each night.
> 
> That's a personal question. Personally, I'd run updatedb every 5 or 6
> hours! And keep backups of the databases. And diff them. I like to know
> what's on my disk.
> 
I let cron run updatedb at around 1AM local time when I am less likely
to be using the machine. It takes only a few minutes because I have
10,000rpm disk drives on an Ultra-2 SCSI controller, 2 CPUs, and a lot
of RAM.

I do not run it more often because it annoys me, but once in a while I
will run it manually if I need to find something that has changed
since the last time it was done. This does not happen very often.

Since locate runs so very much faster than find, I do want updatedb to
be run frequently enough.

-- 
 .~.  Jean-David Beyer           Registered Linux User 85642.
 /V\                             Registered Machine    73926.
/( )\ Shrewsbury, New Jersey     http://counter.li.org 
^^-^^ 1:50pm up 14 days, 20:38, 3 users, load average: 3.29, 3.15,
3.19

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

From: Jean-David Beyer <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.admin,comp.os.linux.help,comp.os.linux.questions
Subject: Re: process just refuses to die!!!!
Date: Mon, 16 Apr 2001 14:00:36 -0400

Wayne Pollock wrote:
> 
> If you used kill -9 <pid> on the correct <pid> and did that as root,
> and the process didn't die, then it must be a zombie. 

Not necessarily: it could be in STATE D, which means it is waiting for
an IO operation to complete. If a kill -9 will not do, the job will
probably never terminate as an interrupt was either not generated by
the device, or lost by the software. The trouble is that, while the
process is not consuming CPU cycles, and may even get swapped out, its
files are open, so it is consuming file descriptors. If it locks the
file, you will never be able to use it unless you reboot the machine.
I wish there were a way around rebooting.

> (That means
> its dead but will still show up in the "ps" output.)  It will not
> run nor take any resources, so don't worry about it.  It will go
> away completely at your next reboot.
> 
> However servers are often watched over by other processes, and if
> one dies another is created to replace it.  Have you checked to make
> sure when you kill the process a new one isn't replacing it?  You may
> need to kill the parent.
> 
> -Wayne Pollock
> 
> me wrote:
> >
> > hi
> >
> > i'm got a crashed process on my system that refuses to terminate. i've
> > killed the window and tried to kill the process with a whole bunch of
> > signals, even kill -9 didnt work.
> >
> > what can i do short of rebooting the system???
> >
> > thanks
> > ali
> >
> > (btw. the process is opera, the web brower)

-- 
 .~.  Jean-David Beyer           Registered Linux User 85642.
 /V\                             Registered Machine    73926.
/( )\ Shrewsbury, New Jersey     http://counter.li.org 
^^-^^ 1:55pm up 14 days, 20:43, 3 users, load average: 2.43, 2.93,
3.09

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

From: [EMAIL PROTECTED] (Kenny McCormack)
Crossposted-To: comp.unix.programmer
Subject: Problem using mmap under Linux (works under Solaris)
Date: 16 Apr 2001 12:59:56 -0500
Reply-To: [EMAIL PROTECTED]

Some time ago (19 Jan, 2001, to be exact), [EMAIL PROTECTED] posted
some sample code for using mmap() to create shared memory between forked
processes.  I adapted it, and the relevant piece is shown below.

Basically, the deal is that in Linux, you use MAP_ANON, and in Solaris, you
use /dev/zero.  The thing works under Solaris, but under Linux, it bombs on
EINVAL.

--- Cut here ---
typedef struct {
    pid_t pid;
    time_t start;
    char s[100];
} shared_area_t;

#ifdef MAP_ANON
    /* Pass -1 as the fd if using MAP_ANON */
    printf("sizeof (shared_area_t) = %d\n",sizeof (shared_area_t));
    vp = mmap(NULL, sizeof (shared_area_t), PROT_READ | PROT_WRITE,
        MAP_SHARED | MAP_ANON, -1, (off_t) 0);
    perror("mmap failed");
    assert(vp != MAP_FAILED);   /* (caddr_t) (-1) */
#endif
--- Cut here ---

Program compiles clean with: gcc -Wall -Werror -s -o mm1 mm1.c && ./mm1
The output is:

--- Cut here ---
sizeof (shared_area_t) = 108
mmap failed: Invalid argument
mm1: mm1.c:30: main: Assertion `vp != ((void *) -1)' failed.
Abort
--- Cut here ---

The man page says:

   EINVAL We don't like start or length  or  offset.   (E.g.,
              they  are  too  large, or not aligned on a PAGESIZE
              boundary.)

Ideas?

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

From: Nix <$}xinix{$@esperi.demon.co.uk>
Crossposted-To: comp.os.linux.development.system,comp.os.linux.development.apps
Subject: Re: Tizek.com is in dire need of a development team...
Date: 16 Apr 2001 19:04:20 +0100

On Mon, 16 Apr 2001, [EMAIL PROTECTED] stipulated:
> If the need is _SO_ desperate, and the destiny for greatness so
> certain, it would seem senseless NOT to spend some of the venture
> capital paying for competent programmers.

The need is *so* desperate that they are engaging in a massive
alphaspam.

> Any venture that plans to altogether defer paying would-be employees
> seems more than a mite shifty to me...

Very so.

-- 
`... and it's not true that I'm closely related to the three-toed
 sloth.' --- Kieran

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

From: "Tauno Voipio" <[EMAIL PROTECTED]>
Subject: Re: Diskless boot from floppy help
Date: Mon, 16 Apr 2001 18:19:07 GMT


"Dan Smith" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
>
> I have read the HOWTo on the subject, but I can't seem to get it to
> work correctly.
>
> I don't want to use lilo yet, unless I have to, since it seems more
> complicated and I don't understand how it works.
>
> I have compiled a small kernel with 'make zImage'.  I have copied it
> to the floppy with 'dd if=kern of=/dev/fd0 bs=1k'.  When I try to boot
> it, the kernel starts to 'load' but I get an error telling me that
> something is in an unsupported compressed format.  What's the deal?
>
> In reference to the lilo way: If I'm creating a filesystem, how do i
> assure that the kernel and compressed filesystem are in the right
> spot?  When I do the 'dd' command with the seek, how am I assured that
> it goes right after the kernel?  The HOWTO has me create a bunch of
> directories, etc, which I would think would get in the way.
>

You have probably forgotten to tell the location of the compressed root file
system to the root. Detailed instructions are in the Bootdisk-HOWTO.

Tauno Voipio
tauno voipio @ iki fi




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

From: Holland King <[EMAIL PROTECTED]>
Subject: Re: How to measure elapsed time?
Date: 16 Apr 2001 18:13:44 GMT

MH <[EMAIL PROTECTED]> wrote:
: Peter T. Breuer wrote:

: Here's what MAN gives me:

: TIME(2)             Linux Programmer's Manual             TIME(2)

you might have to install it try:
man -k time
and if you don't get time (1) 
then try 
apt-get install time

-- 
---
Joseph Holland King  | "God whispers to us in our pleasures, speaks in our
                     |  conscience, but shouts in our pains: it is His
                     |  megaphone to rouse a deaf world." C. S. Lewis

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

From: toy <[EMAIL PROTECTED]>
Crossposted-To: alt.os.linux
Subject: inittab question
Date: Mon, 16 Apr 2001 14:28:55 -0400

I noticed in inittab, control alt delete is where reboot or whatever is
set.  Are there other keys I can map there?  I didn't find the correct
information in the inittab man page.  Where can I map other keys and how
would i do it?

Thanks


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

From: [EMAIL PROTECTED] (Dan Mercer)
Subject: Re: READ THIS!!!Here is the technical explanation!
Date: 16 Apr 2001 18:07:57 GMT

In article <RTFC6.160087$[EMAIL PROTECTED]>,
[EMAIL PROTECTED] writes:
> [EMAIL PROTECTED] (Dan Mercer) writes:
>> In article <[EMAIL PROTECTED]>,
>> Jason <[EMAIL PROTECTED]> writes:
>> > Jason wrote:
>> >>
>> >> If this is the wrong newsgroup, sorry.
>> >> Hi, I have an important question, I'm not trying to cause trouble, but
>> >> why is it that Internet Explorer  for Microsoft runs so much faster than
>> >> any browser on Linux?
>> > 
>> > It's not. It's faster than Netscape or Mozilla for some things,
>> > but is slow as a sloth compared to Konqueror and many of the other
>> > borwsers out there.
>> > 
>> > In part, IE has going for it that portions of the browser reside in the
>> > kernel instead of user space, and it uses DirectDraw for some rendering
>> > (and Netscape etc don't use DRI). Also, IE uses the native widget set
>> > whereas Netscape uses the poorly design Motif widget set. In comparison,
> 
>> Motif is hardly "poorly designed".  Netscape's implementation on
>> Motif was very poor.  Netscape's ignorance is not Motif's fault.
> 
> Hmm...  Motif has long been famed for requiring applications to have
> quite a lot of workarounds for bugs that accreted over the years.  And
> of course, once there's a substantial codebase out there that
> _depends_ on working around the bugs, that makes it impossible to fix
> them.
> 
> <http://ecco.bsee.swin.edu.au/unix/uh/motif.html>
> <http://catalog.com/hopkins/unix-haters/x-windows/disaster.html>

The slow startup time for Netscape comes from doing an XListFonts
which ties up the server,  even though there is no earthly reason for
doing so.  I also suspect that Netscape doesn't defer window
instantiation which would also slow things down.  It's odd,  considering
Netscape's roots in Mosaic,  that it was such a poor implementation,
as if Mosaic was rewritten in Windows,  then the Windows implementation
re-implemented in Motif.

-- 
Dan Mercer
[EMAIL PROTECTED]



-- 
(concatenate 'string "cbbrowne" "@acm.org")
http://www.ntlug.org/~cbbrowne/resume.html
"If the  future navigation system [for  interactive networked services
on the NII] looks like  something from Microsoft, it will never work."
-- Chairman of Walt Disney Television & Telecommunications



Opinions expressed herein are my own and may not represent those of my employer.


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

Crossposted-To: comp.os.linux.advocacy,comp.os.linux.hardware
Subject: Re: Could Linux be used in this factory environment ?
From: Paul Repacholi <[EMAIL PROTECTED]>
Date: 17 Apr 2001 01:57:16 +0800

"Erik Funkenbusch" <[EMAIL PROTECTED]> writes:

> "franek" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]...

> > I could never understand this enamoration with HTML-based
> > interfaces.  There's a good case for using HTML in a normal
> > web-based environment, but why the hell one would want to use this
> > crude and slow method in a standalone system is beyond me.

> Well, there are a lot of reasons why one might want to do this.

> 1) rollout of new versions is effortless.  Just install the new
> pages, scripts, etc.. and it just works the next time they load a
> page.  You can do this by centralizing the apps in a traditional
> environment as well, but then you have to get everyone to exit their
> processes and reload.  This isn't something you would want to do
> automatically because users might have a page up for a specific
> reason, and killing it on them could be disasterous.

> 2) You can use very low-end hardware for terminals (win 3.1 boxes
> even).

Great if you have no solvents, dust, high power machinery...

As I said, get factory experience and understand *the* factory.
Cutting $20 bucks won't go far when you are explaining the reasons for
destroying $100M of plant and killing 5 people.

Oh, and rolling out new versions is NEVER effortless. It can take 6
months or more of extensive testing before you 'roll out'. And if you
think that it becomes easier by adding a huge jump in complexity...

-- 
Paul Repacholi                               1 Crescent Rd.,
+61 (08) 9257-1001                           Kalamunda.
                                             West Australia 6076
Raw, Cooked or Well-done, it's all half baked.

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

From: [EMAIL PROTECTED]
Crossposted-To: comp.os.linux.development.system,comp.os.linux.development.apps
Subject: Re: Tizek.com is in dire need of a development team...
Date: Mon, 16 Apr 2001 19:22:30 -0000

In comp.os.linux.development.system [EMAIL PROTECTED] wrote:
| [EMAIL PROTECTED] writes:
|> There is no pay (yet) but once we get going income will be generated
|> through advertisements on the site and various other services which
|> we will offer, and there will surely be enough to go around.
|
|> Brief Overview:
|
|> TizEK.com is destined to be THE premiere Internet portal for techies
|> and geeks alike. We currently need graphic developers, HTML authors,
|> PHP, CGI/PERL authors, and creative minds. To apply, mail us at
|> [EMAIL PROTECTED]
|
| If the need is _SO_ desperate, and the destiny for greatness so
| certain, it would seem senseless NOT to spend some of the venture
| capital paying for competent programmers.
|
| Any venture that plans to altogether defer paying would-be employees
| seems more than a mite shifty to me...

Seems that way to me, too, especially considering their authority
DNS servers don't even know what "tizek.com" is.

And this is the Nth site to claim this, where N is significantly
larger than the number of portal sites that will ever see the light
of visiting users, much less actual ad revenue.

s/is destined/has a wild dream/

Besides, I'm too busy building my own premiere Internet portal for
techies and geeks alike.  At least my DNS works.  At least I have
an MX record.

-- 
=================================================================
| Phil Howard - KA9WGN |   Dallas   | http://linuxhomepage.com/ |
| [EMAIL PROTECTED] | Texas, USA | http://phil.ipal.org/     |
=================================================================

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

From: * Tong * <[EMAIL PROTECTED]>
Crossposted-To: comp.unix.questions
Subject: Changing the paper size for PS files
Date: 16 Apr 2001 16:29:03 -0300

Hi,

I got a PS file that is for A4 paper. Is there any way that I can
print the A4 ps file nicely on my letter ps printer? 

Thanks!

-- 
Tong (remove underscore(s) to reply)
  *niX Power Tools Project: http://xpt.sourceforge.net/
  http://members.xoom.com/suntong001/
  - All free contribution & collection

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

From: [EMAIL PROTECTED] (Kevin)
Subject: Re: 4 pages per sheet, double sided
Date: Mon, 16 Apr 2001 19:53:11 GMT

Here's a script that prints 4 pages per sheet, but not double
sided.  It's letter size, not A4.  But, it's probably a good start.


#!/bin/sh

PWD=`/usr/bin/pwd`
RM="/usr/bin/rm -f"
SCRIPT=`/usr/bin/basename $0`
TMPDIR="/tmp"

GS_LIB="/usr/local/lib/ghostview:${GSLIB}"
PATH="/usr/local/bin:$PATH"
export GS_LIB PATH

# Expected file order is lower-left, lower-right, upper-left, upper-right
if test $# -ne 4
then
        echo "$SCRIPT: please supply exactly 4 file names" 1>&2
        exit 1
else
        cp $1 ${TMPDIR}/ll-$$.ps
        cp $2 ${TMPDIR}/lr-$$.ps
        cp $3 ${TMPDIR}/ul-$$.ps
        cp $4 ${TMPDIR}/ur-$$.ps
fi

# Input files must end in ".ps" to satisfy Ghostscript.
# Output files will end in ".epsi" due to ps2epsi.

cd ${TMPDIR}
for file in ll-$$.ps lr-$$.ps ul-$$.ps ur-$$.ps
do
        ps2epsi $file
done

# The last, and only the last, epsffit command needs "-s" to get
# anything to print.
epsffit -c 36 36 288 378        ul-$$.epsi > test1-$$.ps
epsffit -c 36 414 288 756       ur-$$.epsi > test2-$$.ps
epsffit -c 324 36 576 378       ll-$$.epsi > test3-$$.ps
epsffit -s -c 324 414 576 756   lr-$$.epsi > test4-$$.ps

cat test1-$$.ps test2-$$.ps test3-$$.ps test4-$$.ps > ${PWD}/4-up.ps

for file in \
test1-$$.ps test2-$$.ps test3-$$.ps test4-$$.ps \
ll-$$.ps lr-$$.ps ul-$$.ps ur-$$.ps \
ll-$$.epsi lr-$$.epsi ul-$$.epsi ur-$$.epsi
do
        ${RM} ${file}
done

# This can be omitted if you don't want a screen view before printing.
gs -q ${PWD}/4-up.ps


In article <9betms$4h4$[EMAIL PROTECTED]>,
 "Andrea Furin" <[EMAIL PROTECTED]> writes:
> How could I print 4 pages per A4 - sheet (position: landscape) in such a way
> that the 2th page is opposite to the 1th and the 4th to the 3th?
> Something like that:
> front:  1th (left)  4th (right)
> behind:  3th (left)  2th (right)
> 
> 
> 
> 

-- 
Unless otherwise noted, the statements herein reflect my personal
opinions and not those of any organization with which I may be affiliated.

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


** 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 by posting to comp.os.linux.misc.

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