Linux-Development-Sys Digest #604, Volume #8      Mon, 2 Apr 01 17:13:12 EDT

Contents:
  Re: HELP!!! Why does this crash the kernel (Kasper Dupont)
  diff question ([EMAIL PROTECTED])
  the kernel size ??? ("hushui")
  Re: the kernel size ??? (Kasper Dupont)
  mt command fails (Manoj Patil)
  Re: How to handle newline character(s) in a TCP server (Villy Kruse)
  Re: How to handle newline character(s) in a TCP server (Andrew Gierth)
  Re: WinZip ("LittleFish")
  Win Modems ("LittleFish")
  Re: Win Modems ("Ari")
  Re: Win Modems (Chris King)
  two question about linux kernel source? ("hushui")
  2.4.3 compile errors? (Harmon Seaver)
  Re: diff question (Markus Kossmann)
  Re: two question about linux kernel source? ("Norm Dresner")
  Re: HELP!!! Why does this crash the kernel (Douglas Hendrix)
  Re: 2.4.3 compile errors? (Rick Ace)
  Problem: Console login not possible when using NIS and network is broken. (Moritz 
Franosch)
  mysql or postgresql? which is better? ("Hans-Peter Maurer")
  Re: How to read/write kernel addr, say c0101000? (Ulrich Eckhardt)

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

From: Kasper Dupont <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: Re: HELP!!! Why does this crash the kernel
Date: Mon, 02 Apr 2001 08:14:08 +0000

Chronos Tachyon wrote:
> 
> On Sun 01 Apr 2001 10:02, Douglas Hendrix wrote:
> 
> > Hi all, I am in desperate need if help :(
> >
>   [Snip]
> >
> > #include <sys/io.h>
> > main()
> > {
> >   iopl(3);
> >   outb(0x3f8+0x4,0x8);
> > }
> >
>   [Snip]
> 
> This crashed the kernel because you probably didn't mean to write the
> number 0x3fc into port 0x08. :-)  Also, your code will conflict with the
> existing serial port driver unless it isn't loaded in the kernel.  Doing
> anything with I/O ports in userspace is inherently painful.
> 

Consider using ioperm() instead of iopl().
With ioperm() you specify a port range, and
is thus much safer. If you had used ioperm()
the incorect outb() line would just have
given a segmentation fault.

-- 
Kasper Dupont

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

From: [EMAIL PROTECTED]
Subject: diff question
Date: Mon, 02 Apr 2001 08:37:12 GMT

Hello,

If you want to use diff to make a patch between the original kernel
and the kernel you changed you can just do this diff on every file you
changed and add it to the same diff file. But when I have created a
new file, diff just won't work on it (because this file doesn't exist
in the original kernel). 
It does work when I do diff -urN (linuxdir)/originalkernel
(linuxdir)/alteredkernel, but then it takes like 10 minutes. The
option N makes sure this will work. But this option doesn't work when
you do a diff on single files...
How do you do this?

Thanks,
Bart

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

From: "hushui" <[EMAIL PROTECTED]>
Subject: the kernel size ???
Date: Mon, 2 Apr 2001 16:42:10 +0800

in boot.h ,it defines the kernel size by the following :
boot.h
/* Don't touch these, unless you really know what you're doing. */
#define DEF_INITSEG 0x9000
#define DEF_SYSSEG 0x1000
#define DEF_SETUPSEG 0x9020
#define DEF_SYSSIZE 0x7F00

7f00 ,what is its unit ??? the number of sectors ???
It is written when compile the kernel????????
what is the  actual kernel size in bytes ???
I am confused about.
I use redhat 6.2 (kernel 2.1.14)
I make config to add ntfs file system supported in my kernel.
And it runs.
But I find the time of  the file (boot.h ) is still 1997 ,not the time when
I compile the kernel (2001).
Why ???? The kernel size is only written in the file of vmlinuz??????



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

From: Kasper Dupont <[EMAIL PROTECTED]>
Subject: Re: the kernel size ???
Date: Mon, 02 Apr 2001 09:21:00 +0000

hushui wrote:
> 
> in boot.h ,it defines the kernel size by the following :
> boot.h
> /* Don't touch these, unless you really know what you're doing. */
> #define DEF_INITSEG 0x9000
> #define DEF_SYSSEG 0x1000
> #define DEF_SETUPSEG 0x9020
> #define DEF_SYSSIZE 0x7F00
> 
> 7f00 ,what is its unit ??? the number of sectors ???
> It is written when compile the kernel????????
> what is the  actual kernel size in bytes ???
> I am confused about.
> I use redhat 6.2 (kernel 2.1.14)
> I make config to add ntfs file system supported in my kernel.
> And it runs.
> But I find the time of  the file (boot.h ) is still 1997 ,not the time when
> I compile the kernel (2001).
> Why ???? The kernel size is only written in the file of vmlinuz??????

The value is used in the file arch/i386/boot/bootsect.S.
In that file you can also read that it is 16-byte units.
It does not mean that the kernel is exactly 508KB, it is
an upper limit. I think it is the upper limit on the
size of a zImage, while a bzImage can be larger.

-- 
Kasper Dupont

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

From: Manoj Patil <[EMAIL PROTECTED]>
Subject: mt command fails
Date: Mon, 02 Apr 2001 15:11:20 +0530

Hi
I have two tapes
1.    Exabyte 8200
2.    Exabyte 8505
(Both are 8MM devices)

For the first tape,  mt -f /dev/nst0    setblk 1024 fails
However I am able to change the block size for the second tape.
Both drives have tape cartridges in it

Can some one suggest why mt fails on the first tape ?

Regards


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

From: [EMAIL PROTECTED] (Villy Kruse)
Crossposted-To: comp.unix.programmer,comp.os.linux.development.apps
Subject: Re: How to handle newline character(s) in a TCP server
Date: 2 Apr 2001 10:57:01 GMT

On Mon, 02 Apr 2001 07:29:34 +0000, Kasper Dupont <[EMAIL PROTECTED]> wrote:

>
>The two char line breaks are not used everywhere on the
>internet. When I fetch a page from my webserver it sends
>only 10 as line break.
>

Actualy it IS used everywhere on the internet.

The http as well as ftp, smtp, and telnet mandates CRLF line terminators
in the protocol.  For ASCII mode ftp that also includes the data files,
which is why the binary/ascii setting is important for a FTP transfer.
The web contents are usualy html where any CR and LF is stripped before
display, and image files which are transfered as is in binary form.
Any mail message is translated to CRLF format before being transferred
via the smtp protocol, and is then up to the receiving system to translate
that to whatever format is suitable for this system.


Villy

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

From: Andrew Gierth <[EMAIL PROTECTED]>
Crossposted-To: comp.unix.programmer,comp.os.linux.development.apps
Subject: Re: How to handle newline character(s) in a TCP server
Date: 02 Apr 2001 12:54:13 +0100

>>>>> "Kasper" == Kasper Dupont <[EMAIL PROTECTED]> writes:

 Kasper> The two char line breaks are not used everywhere on the
 Kasper> internet. When I fetch a page from my webserver it sends only
 Kasper> 10 as line break.

HTTP relaxes the CRLF requirements for the contents of text entity
bodies only; protocol elements such as header lines must still use
CR+LF.

-- 
Andrew.

comp.unix.programmer FAQ: see <URL: http://www.erlenstar.demon.co.uk/unix/>
                           or <URL: http://www.whitefang.com/unix/>

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

From: "LittleFish" <littlefish_au[SPAM ME AT YOUR OWN RISK]@yahoo.com>
Subject: Re: WinZip
Date: Mon, 2 Apr 2001 14:59:22 +1000

That work's, I have done this before!
Littlefish
"Kasper Dupont" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
> ray wrote:
> >
> > I have a file compressed using WinZip program in Windows.
> > Can I decompress it at Linux?
> > Thanks
>
> You can just use unzip. I think it is installed
> by default on RedHat systems, I don't know about
> other distributions.
>
> --
> Kasper Dupont



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

From: "LittleFish" <littlefish_au[SPAM ME AT YOUR OWN RISK]@yahoo.com>
Crossposted-To: 
alt.computer.drivers,alt.os.linux,aus.computers.linux,comp.os.linux.development.apps,comp.os.linux.hardware
Subject: Win Modems
Date: Mon, 2 Apr 2001 15:06:02 +1000

It seems as if more and more people using Windows
are very dissapointed over the performance of there Lucent Winmodems. In the
last week I have met 3 people that have taken back there Lucent Winmodem
because it drops out regularly. If your machine is slower 300Mhz or is
running a CPU intensive task in the background you can bet that it will drop
out. Give me a real modem anyday!! By the way real internal modems are
getting hard to source. Does anyone have suggestions for a Internal Fax
Voice Data modem?
LittleFish
--
 Remove [SPAM ME AT YOUR OWN RISK] to mail me.



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

From: "Ari" <[EMAIL PROTECTED]>
Crossposted-To: 
alt.computer.drivers,alt.os.linux,aus.computers.linux,comp.os.linux.development.apps,comp.os.linux.hardware
Subject: Re: Win Modems
Date: Mon, 2 Apr 2001 21:32:58 +0800

DirectCom used to make good internal hardware modems, but I think all their
internals are now winmodems...ask a few dealers to check this out for you.

Ari


"LittleFish" <littlefish_au[SPAM ME AT YOUR OWN RISK]@yahoo.com> wrote in
message news:cv_x6.7845$[EMAIL PROTECTED]...
> It seems as if more and more people using Windows
> are very dissapointed over the performance of there Lucent Winmodems. In
the
> last week I have met 3 people that have taken back there Lucent Winmodem
> because it drops out regularly. If your machine is slower 300Mhz or is
> running a CPU intensive task in the background you can bet that it will
drop
> out. Give me a real modem anyday!! By the way real internal modems are
> getting hard to source. Does anyone have suggestions for a Internal Fax
> Voice Data modem?
> LittleFish
> --
>  Remove [SPAM ME AT YOUR OWN RISK] to mail me.
>
>



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

From: Chris King <[EMAIL PROTECTED]>
Crossposted-To: 
alt.computer.drivers,alt.os.linux,aus.computers.linux,comp.os.linux.development.apps,comp.os.linux.hardware
Subject: Re: Win Modems
Date: Mon, 02 Apr 2001 22:07:05 +0800
Reply-To: [EMAIL PROTECTED]

On Mon, 2 Apr 2001 15:06:02 +1000, "LittleFish" <littlefish_au[SPAM ME
AT YOUR OWN RISK]@yahoo.com> wrote:

>Give me a real modem anyday!! By the way real internal modems are
>getting hard to source. Does anyone have suggestions for a Internal Fax
>Voice Data modem?

Perhaps the 'big list' at the following address will help you decide:

   http://www.idir.net/~gromitkc/winmodem.html

-Chris


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

From: "hushui" <[EMAIL PROTECTED]>
Subject: two question about linux kernel source?
Date: Mon, 2 Apr 2001 23:06:08 +0800

1.int bootsect.S  , the variable  root_dev  is standing for the root device
???
Is ROOT_DECV defined when compile a kernel ???
2.When we use lilo ,not bootsect.S , does lilo load setup.S code to the
memory???
 In setup.S ,the following source codes confuse me .

..............
mov bl,[497] ! get setup sects from boot sector
sub bx,#4  ! LILO loads 4 sectors of setup !! why sub 4????????
 shl bx,#8  ! convert to words
 mov cx,bx
 shr bx,#3  ! convert to segment
 add bx,#SYSSEG
 seg cs
 mov start_sys_seg,bx
! Move rest of setup code/data to here
 mov di,#2048 ! four sectors loaded by LILO
  sub si,si
 mov ax,cs  ! aka #SETUPSEG  0x9020
 mov es,ax
 mov ax,#SYSSEG  0x1000  ( for zImage )
 mov ds,ax
 rep
 movsw
...........
During these code , the source place is 0x1000:0 while the destination place
is 0x9020:#2048 .
what is cx ?? What is the relationship between those code and lilo (which is
used to load the bzImage to 0x100000 )?????????
After this ,the codes  followed those check  setup_sig1 and setup_sig2 again
??
why??

3x



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

From: Harmon Seaver <[EMAIL PROTECTED]>
Subject: 2.4.3 compile errors?
Date: Mon, 02 Apr 2001 16:43:38 GMT

  Trying to comile kernel 2.4.3 on Redhat 7.0 on a Cyrix 200, Asus TX97E
motherboard, I got a segfault. When I went to report it on bugzilla, I noticed
someone else getting a segfault with 2.4.0, and the answer was to use kgcc. So,
I changed the Makefile to use kgcc instead of gcc, then I got "kgcc: Internal
compiler error: program cc1 got fatal signal 11, then a bunch more stuff like
[rsrc_mgr.o] Error 1, [first_rule] Error 2, [subdir_pcmcia] Error 2,
[dir_drivers] Error 2, and then an Assembler meesage about end of file  not at
end of line, etc.
   I don't see any other posts of problems with 2.4.3, here or on bugzilla. I
didn't have much problem compiling 2.4.1 or 2.4.2. 


-- 
Harmon Seaver, MLIS     
CyberShamanix
Work 920-203-9633   [EMAIL PROTECTED] 
Home 920-233-5820       [EMAIL PROTECTED]

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

From: Markus Kossmann <[EMAIL PROTECTED]>
Subject: Re: diff question
Date: Mon, 02 Apr 2001 18:36:52 +0200

[EMAIL PROTECTED] wrote:
> 
> Hello,
> 
> If you want to use diff to make a patch between the original kernel
> and the kernel you changed you can just do this diff on every file you
> changed and add it to the same diff file. But when I have created a
> new file, diff just won't work on it (because this file doesn't exist
> in the original kernel).
> It does work when I do diff -urN (linuxdir)/originalkernel
> (linuxdir)/alteredkernel, but then it takes like 10 minutes. The
> option N makes sure this will work. But this option doesn't work when
> you do a diff on single files...
> How do you do this?
> 
Try  "diff /dev/null new_file" 
-- 
Markus Kossmann                                    
[EMAIL PROTECTED]

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

From: "Norm Dresner" <[EMAIL PROTECTED]>
Subject: Re: two question about linux kernel source?
Date: Mon, 02 Apr 2001 17:52:37 GMT

Here's a partial answer.  See in-line below.

    Norm

hushui <[EMAIL PROTECTED]> wrote in message
news:9aa4ct$[EMAIL PROTECTED]...
> 1.int bootsect.S  , the variable  root_dev  is standing for the root
device
> ???
> Is ROOT_DECV defined when compile a kernel ???
> 2.When we use lilo ,not bootsect.S , does lilo load setup.S code to the
> memory???
>  In setup.S ,the following source codes confuse me .
>
> ..............
> mov bl,[497] ! get setup sects from boot sector
> sub bx,#4  ! LILO loads 4 sectors of setup !! why sub 4????????
>  shl bx,#8  ! convert to words
>  mov cx,bx

    The CX register contains the count for the subsequent movesw instruction

>  shr bx,#3  ! convert to segment
>  add bx,#SYSSEG
>  seg cs
>  mov start_sys_seg,bx
> ! Move rest of setup code/data to here
>  mov di,#2048 ! four sectors loaded by LILO
>   sub si,si
>  mov ax,cs  ! aka #SETUPSEG  0x9020
>  mov es,ax
>  mov ax,#SYSSEG  0x1000  ( for zImage )
>  mov ds,ax
>  rep
>  movsw                                        <===================
> ...........
> During these code , the source place is 0x1000:0 while the destination
place
> is 0x9020:#2048 .
> what is cx ??




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

From: Douglas Hendrix <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: Re: HELP!!! Why does this crash the kernel
Date: Mon, 02 Apr 2001 18:28:45 GMT

Chronos Tachyon wrote:
> 
> On Sun 01 Apr 2001 10:02, Douglas Hendrix wrote:
> 
> > Hi all, I am in desperate need if help :(
> >
>   [Snip]
> >
> > #include <sys/io.h>
> > main()
> > {
> >   iopl(3);
> >   outb(0x3f8+0x4,0x8);
> > }
> >
>   [Snip]
> 
> This crashed the kernel because you probably didn't mean to write the
> number 0x3fc into port 0x08. :-)  Also, your code will conflict with the
> existing serial port driver unless it isn't loaded in the kernel.  Doing
> anything with I/O ports in userspace is inherently painful.


Thanks,

you're right.  I forgot that the linux outb has the 
parameters in the different order than DOS and QNX.

Doug

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

From: Rick Ace <[EMAIL PROTECTED]>
Subject: Re: 2.4.3 compile errors?
Date: Mon, 02 Apr 2001 13:40:41 -0400

Harmon Seaver wrote:
> 
>   Trying to comile kernel 2.4.3 on Redhat 7.0 on a Cyrix 200, Asus TX97E
> motherboard, I got a segfault. 

This is a truly superb article about segfaults occurring during kernel
compilation
and their possible causes.

  http://www.bitwizard.nl/sig11/

Hopefully it will get you headed in the right direction for a solution.

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

From: Moritz Franosch <[EMAIL PROTECTED]>
Subject: Problem: Console login not possible when using NIS and network is broken.
Date: 02 Apr 2001 20:45:00 +0200



Hello,


We have the following problem on our machines here. We use NIS to
deliver /etc/passwd to all our machines. Normally, all users and root
can log in at a linux console as they should. 

But if the network is broken (e.g. the NIS server is down, the network
cable is plugged out or a switch is broken or not connected by some
reason) none can log in at a linux console, not even root. After
'Login: root [RETURN]' the console window hangs.

However, it should be possible for users listed in the local
/etc/passwd to log in even if NIS is unavailable, because 'files' have
precedence over 'nis' in /etc/nsswitch.conf (info libc -> NSS
Configuration File). But in fact not even root can log into the
machine, so the only possibility is to press reset. If the machine is
booted in runlevel 1 (single user mode), root can login as NIS is
totally disabled then.


Is there a way to configure NIS such that root can always log in even
if the NIS server is down or the network is broken?


Thank you for your help,

Moritz




Some information about our configuration follows.


We use SuSE 7.1 with kernel 2.2.18. But the problem seems to be rather
independent of the system because we had the same problem with SuSE 6.2.


/etc/nsswitch.conf is:

passwd: files nis
group: files nis

hosts:          files dns
networks:       files dns

services:       files
protocols:      files
rpc:            files
ethers:         files
netmasks:       files
netgroup:       files
publickey:      files

bootparams:     files
automount:      files
aliases:        files


Our local /etc/passwd looks like this:

root:x:0:0:root:/root:/bin/bash
bin:x:1:1:bin:/bin:/bin/bash
...
nobody:x:65534:65534:nobody:/var/lib/nobody:/bin/bash
+::::::


Our local /etc/shadow looks like this:

root:XXXXXXXXXXXXX:11368:0:10000::::
...
nobody:*:0:0:10000::::


The output of 'ypcat passwd' looks like this:

user1:XXXXXXXXXXXXX:9496:9108:XXX:/home/user1:/bin/bash
user2:XXXXXXXXXXXXX:10875:9108:XXX:/home/user2:/bin/bash

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

From: "Hans-Peter Maurer" <[EMAIL PROTECTED]>
Subject: mysql or postgresql? which is better?
Date: Mon, 2 Apr 2001 21:42:09 +0200

Hello world!

i am looking for the best free database for linux:

which is better mysql or postgresql? Which is more reliable and more
powerful...?

Thanks in advance!

best from germany

Peter



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

From: Ulrich Eckhardt <[EMAIL PROTECTED]>
Subject: Re: How to read/write kernel addr, say c0101000?
Crossposted-To: comp.os.linux.setup
Date: Mon, 2 Apr 2001 22:41:17 +0200

Gu Weining x-posted:
> 
> 
> In my driver, I try to read/write some kernel address.
> But I always got Segmentation fault. Sounds like my
> access method is wrong. I copied my char driver code
> running with Linux v2.2.1x as follows:
> 
>   int address, value;
>   address = 0xc0101000;
>   address = address - PAGE_OFFSET;
>   /* even I set either PAGE_OFFSET=0 or
>                        PAGE_OFFSET=c0000000, still wrong */
> 
>   value = (*(int *)address);
this is where either the access violation takes place or where you corrupt 
your stack so that the next action fails. Why don't you start with 
something like
int* mem;
mem = (int*)((char*)0xc0101000 - PAGE_OFFSET);

>   value++;                         /* access this address */
your're not accessing the memory at the address here, your incrementing a 
local variable.


> ****** Segmentation fault ******
> 
> Would you please give me some hint? Thank you so much.
Would you please stop crossposting then? Post it to whatever is sensible 
and set an as well sensible follow-up.



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


** 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 the
comp.os.linux.development.system newsgroup.

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-Development-System Digest
******************************

Reply via email to