Linux-Development-Sys Digest #297, Volume #8 Fri, 24 Nov 00 09:13:11 EST
Contents:
Re: Database in Redhat Linux (Madr)
make C prog put itself in background??? (Joe Morris)
Re: make C prog put itself in background??? (proton)
Student Needs Your Help ("]")
Linux on mainframe (Nilesh Patel)
Linux kernel developers: Call for Interviews (Steve Frampton)
Re: make C prog put itself in background??? (Erik Hensema)
Re: modify syscall readdir read (Thiemo Voigt)
Re: Student Needs Your Help (Steve Frampton)
[Q] How to get the Ethernet address ? ("Pillonel =?ISO-8859-2?Q?C=E9dric?=,
NWS-PD-71")
C Autoresponder For Linux ("Adrian")
Re: injecting keystrokes into virtual console ([EMAIL PROTECTED])
Re: Linux on mainframe ([EMAIL PROTECTED])
Re: query: Controlling SCSI disks under Linux (Ronald Cole)
Re: GLIBC Hash Functions - Please Help... (Arnstein Oseland)
Re: ext2 fs on magneto optical disks ("Massimiliano Caovilla")
where should I put modules to make modprobe find them??? ("Massimiliano Caovilla")
Re: where should I put modules to make modprobe find them??? ("Peter T. Breuer")
extend the blocksize (root)
Re: extend the blocksize (Josef Moellers)
Block number numbering scheme (Sean)
----------------------------------------------------------------------------
From: Madr <[EMAIL PROTECTED]>
Crossposted-To:
comp.os.linux.development.apps,comp.os.linux.apps,comp.os.linux.misc,comp.lang.java.databases,comp.databases.informix,comp.databases.oracle.server,comp.databases.sybase,linux.redhat.misc,linux.postgres,comp.databases.pick,comp.databases.ibm-db2,comp.databases.oracle.misc
Subject: Re: Database in Redhat Linux
Date: Thu, 23 Nov 2000 12:14:38 +0100
Freelancer wrote:
> I need decide which database going to run for Redhat Linux.
> I know MySQL is the most popular one in Linux world. I need
> you help me to fill out the blank and hole (?) in table below.
>
> Databases for Linux (Redhat)
> Y -- yes; N -- No; NA -- not apply; ? -- don't know/not sure
>
Database Trigger/Store Procedure Transaction Foreign Key Constrain
JDBC/RowSet C/C++ Library PerlDBI
Postgres Y Y
Y N
?/? Y/N Y?
Informix Y Y
Y Y
? ? ?
--
Martin Dressler
e-mail: [EMAIL PROTECTED]
http://www.musicabona.com/
------------------------------
From: Joe Morris <[EMAIL PROTECTED]>
Subject: make C prog put itself in background???
Date: Thu, 23 Nov 2000 16:51:12 -0500
I have a C program that acts as an interactive shell. It takes command line
arguments from keyboard and tokenizes them, puts teh srgs in an array of
strings, then calls fork and execvp from child, which starts any program you
might want to run, such as grep, etc, and also passes it the arguments it
needs, which were in the command line args input by user.
But I want to make the program that is called (before the execvp call) to
run
in the background. And then, while it is running in the background, the
interactive shell will run in the foreground.
I know how to execute a program from the various standard unix shells--
append '&' to the end of your command line string-- but that is not what I
want to do. I want to make a C program MAKE ITSELF run in the background.
TIA
------------------------------
From: proton <[EMAIL PROTECTED]>
Subject: Re: make C prog put itself in background???
Date: Fri, 24 Nov 2000 00:03:41 GMT
Joe Morris wrote:
> I want to make a C program MAKE ITSELF run in the background.
Well essentially it should be in the `background' as long as
you dont wait() for it.
To run it as a daemon you normally close() stdin, stdout and
stderr, and optionally setsid() to create a new session.
This is all described very well in the C FAQ AFAIK. Look it
up, its quite informative.
/proton
------------------------------
From: "]" <[EMAIL PROTECTED]>
Subject: Student Needs Your Help
Date: Thu, 23 Nov 2000 15:40:01 -0800
I am a student at UCI doing a project on open source communities. Can you
take a few minutes and complete a questionnaire? If you can help me by
doing this, please click on:
http://www.ics.uci.edu/~snarisim
Thanks,
Tony
------------------------------
From: Nilesh Patel <[EMAIL PROTECTED]>
Subject: Linux on mainframe
Date: Fri, 24 Nov 2000 11:43:01 -0500
We have a Linux running on a Mainframe. It is 2.2.16.
When I try to do cat /proc/interrupts it returns with bad file
descriptor error.
I also tried
strace lsdev .
It was able to open /proc/interrupts and other proc entries but was not
able to read the file.
What is the problem ?
Is the code for proc entry for interrupts is buggy and others reporting
the same problem buggy ?
cat /proc/meminfo and some other entries show meaningful values.
Nilesh
------------------------------
From: Steve Frampton <[EMAIL PROTECTED]>
Subject: Linux kernel developers: Call for Interviews
Crossposted-To: comp.os.linux.development
Date: 24 Nov 2000 16:08:21 +0900
Hello!
At the beginning of October, I started up http://www.kerneltrap.com,
a news and discussion site devoted to low-level systems programming
and related topics such as embedded systems development, hardware
hacking, and OS kernel development.
Obviously it takes time for any site to get going, but the visitor count
for kerneltrap has been gradually increasing. Kerneltrap gets just over
3000 hits a day now (much lower than I'd like, but that'll come). As
kerneltrap is linked by more sites, and hits more search engines, these
numbers should continue to grow.
Up to now, with a limited audience, kerneltrap has been mainly a links
site to related articles, stories, tutorials, etc. as found around the
web. I'd really like to change that, and offer some original content on
the site.
To start with, what I'd really enjoy is to interview anybody who is
significantly involved in Linux kernel development. I'd like to ask about
your level of involvement, how long you've been a contributor, and other
related questions. This would help draw more users to my site, while at
the same time increase your exposure in the community and give you the ego
stoking you deserve. ;-)
If you're interested, please send an e-mail to [EMAIL PROTECTED]
with a brief blurb on yourself and your involvement, and if you are indeed
``worthy'' of global adoration [ ;-) ] I'll send you the questions list.
Thanks!
==============< LINUX: The choice of a GNU generation. >==============
Steve Frampton <[EMAIL PROTECTED]> interQ (Japan), Inc.
Systems Administrator/Software Developer http://www.interq.or.jp/
------------------------------
From: [EMAIL PROTECTED] (Erik Hensema)
Subject: Re: make C prog put itself in background???
Date: Thu, 23 Nov 2000 23:59:00 +0100
Reply-To: [EMAIL PROTECTED]
Joe Morris ([EMAIL PROTECTED]) wrote:
>I have a C program that acts as an interactive shell. It takes command
>line arguments from keyboard and tokenizes them, puts teh srgs in an
>array of strings, then calls fork and execvp from child, which starts
>any program you might want to run, such as grep, etc, and also passes
>it the arguments it needs, which were in the command line args input by
>user.
>But I want to make the program that is called (before the execvp
>call) to run in the background. And then, while it is running in the
>background, the interactive shell will run in the foreground. I know
>how to execute a program from the various standard unix shells--
>append '&' to the end of your command line string-- but that is not
>what I want to do. I want to make a C program MAKE ITSELF run in the
>background.
#v+
void
become_daemon()
{
int i;
if(fork()) {
/* Parent */
exit(0);
}
/* Start new session */
setsid();
/* Close low fd's and reopen as /dev/null */
for(i=0; i < 3; i++) {
close(i);
open("/dev/null", O_RDWR, 0);
}
}
#v-
I reopen the low fd's because sometimes some calls like to write to stdout
or stderr, cluttering up the console. Writing to /dev/null hurts nobody.
--
Erik Hensema ([EMAIL PROTECTED])
Please note that my From: field is spamtrapped.
------------------------------
From: Thiemo Voigt <[EMAIL PROTECTED]>
Crossposted-To: de.comp.os.unix.linux.misc,linux.dev.kernel,linux.sources.kernel
Subject: Re: modify syscall readdir read
Date: Fri, 24 Nov 2000 08:32:31 +0000
The code for the proc file system stuff is (this is Linux 2.4) in /fs/proc.
I guess (but I am not sure) that you should be able to read current (process
who made the call), get its pid, get the owner (uid) of the process
(not sure about that but look it up) and compare to the other processes running
and their owners.
Thiemo
------------------------------
From: Steve Frampton <[EMAIL PROTECTED]>
Subject: Re: Student Needs Your Help
Date: 24 Nov 2000 18:07:16 +0900
] <[EMAIL PROTECTED]> wrote:
> I am a student at UCI doing a project on open source communities. Can you
> take a few minutes and complete a questionnaire? If you can help me by
> doing this, please click on:
> http://www.ics.uci.edu/~snarisim
Not Found
The requested URL /~snarisim was not found on this server.
Well, I tried.
==============< LINUX: The choice of a GNU generation. >==============
Steve Frampton <[EMAIL PROTECTED]> interQ (Japan), Inc.
Systems Administrator/Software Developer http://www.interq.or.jp/
------------------------------
From: "Pillonel =?ISO-8859-2?Q?C=E9dric?=, NWS-PD-71"
Crossposted-To: comp.sys.sun.misc,comp.os.linux.setup
Subject: [Q] How to get the Ethernet address ?
Date: Fri, 24 Nov 2000 10:17:57 +0100
Reply-To: [EMAIL PROTECTED]
How can I get the Ethernet address from my C++ application ?
Thanks.
================================================================
Cedric Pillonel |
Swisscom | phone: +41 (0)31 342 45 74
NWS-ENG-V-VT | Fax: +41 (0)31 342 59 59
Zentweg 9 | e-mail: [EMAIL PROTECTED]
CH-3000 Berne 30, Switzerland |
================================================================
------------------------------
From: "Adrian" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: C Autoresponder For Linux
Date: Fri, 24 Nov 2000 20:25:24 +1100
Hi All,
Im looking for some code to get started on making a custom e-mail auto
responder. Realy need some help or something to start me off. If anyone
has some code, links or could give me a sample that would allow me to
manipulate the mail in the mail server etc that would be cool.
Any help would be appreciated!
Thanks
Ad
------------------------------
From: [EMAIL PROTECTED]
Subject: Re: injecting keystrokes into virtual console
Date: Fri, 24 Nov 2000 09:42:03 -0000
On Wed, 22 Nov 2000 17:30:16 GMT Mike McDonald <[EMAIL PROTECTED]> wrote:
| In article <[EMAIL PROTECTED]>,
| [EMAIL PROTECTED] writes:
|> On Tue, 21 Nov 2000 18:52:26 GMT Mike McDonald <[EMAIL PROTECTED]> wrote:
|>
|>| If you're using bash as your shell (I'm not), you could have your special
|>| getty program gather up the init commands into a temp file and then exec bash
|>| as 'bash -rcfile /tmp/fooy -i'. That'll cause bash to execute the init
|>| commands first and then continue on as an interactive shell. You might be able
|>| to do a similar thing with other shells too.
|>
|> That could be really messy with more than one going at the same time.
|
| Huh? /tmp/fooy was an example temp file name. You'd actually want to use
| mktemp() and have the script remove its self as its last action. I don't see
| how it's "messy" at all. Please explain what you mean.
It would have to mix these with the normal init commands from .bashrc
since with -rcfile, .bashrc is not used.
Then there remains the issue of how to inject the input into the program
being started AND have that program accept input from the keyboard and
not get an EOF when there's no more initializing input.
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: [EMAIL PROTECTED]
Subject: Re: Linux on mainframe
Date: Fri, 24 Nov 2000 09:48:33 -0000
On Fri, 24 Nov 2000 11:43:01 -0500 Nilesh Patel <[EMAIL PROTECTED]> wrote:
| We have a Linux running on a Mainframe. It is 2.2.16.
| When I try to do cat /proc/interrupts it returns with bad file
| descriptor error.
| I also tried
| strace lsdev .
| It was able to open /proc/interrupts and other proc entries but was not
| able to read the file.
| What is the problem ?
| Is the code for proc entry for interrupts is buggy and others reporting
| the same problem buggy ?
| cat /proc/meminfo and some other entries show meaningful values.
If you are referring to an IBM 390 mainframe, there is probably a very
good reason for this. The channel I/O architecture of the 360 to 390
series does not do interrupts the same way as PCs. There are no IRQ
levels. Instead, all I/O interrupts are given the channel/device address
directly. Once you understand the scheme, it's really a much better one
(no more conflicting IRQs or interrupt allocation issues). Since the
/proc/interrupts interface was really for these IRQ levels, and since
that IRQ code is not in the 390 architecture specific parts, that might
explain why it isn't working.
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: Ronald Cole <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps,comp.periphs.scsi
Subject: Re: query: Controlling SCSI disks under Linux
Date: 24 Nov 2000 02:09:52 -0800
Alain-Pierre CHERTIER <[EMAIL PROTECTED]> writes:
> Hello Kevin !
> CONCLUSION : /dev/sgx minor numbers don't have ANYTHING to do, to see,
> or to be compared or associated with physical SCSI IDs
Truly a f*cked arrangement... my /dev/scd0 is SCSI ID 2, but
consistently shows up at /dev/sg1 on my RedHat box.
/etc/security/console.perms takes care of /dev/cdrom, but neglects
a useful entry for the generic device (which grip() likes to use).
Anybody got a good suggestion for a name for such a link?
--
Forte International, P.O. Box 1412, Ridgecrest, CA 93556-1412
Ronald Cole <[EMAIL PROTECTED]> Phone: (760) 499-9142
President, CEO Fax: (760) 499-9152
My GPG fingerprint: C3AF 4BE9 BEA6 F1C2 B084 4A88 8851 E6C8 69E3 B00B
------------------------------
From: Arnstein Oseland <[EMAIL PROTECTED]>
Subject: Re: GLIBC Hash Functions - Please Help...
Date: Fri, 24 Nov 2000 11:15:35 +0100
Stephanie & Gary Sanders wrote:
>
> I can't seem to find any decent documentation on the glibc functions.
> The HOWTO I found is all about compiling it, and nothing about using
> it. Any help ( particularly with the hash functions ) would be greatly
> appreciated.
General doc on glibc: http://www.gnu.org/manual/glibc-2.0.6/libc.html
- Arnstein
------------------------------
From: "Massimiliano Caovilla" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.misc
Subject: Re: ext2 fs on magneto optical disks
Date: Fri, 24 Nov 2000 12:19:19 +0100
Marc SCHAEFER <[EMAIL PROTECTED]> wrote in message
8viudm$sog$[EMAIL PROTECTED]
> In comp.os.linux.development.system Massimiliano Caovilla
<[EMAIL PROTECTED]> wrote:
> : Any suggestions?
>
> There was something about the need to change the partitionning
information.
> I don't remember what it was exactly, but maybe you can find it with
> a search engine.
>
> Now, to exclude that possibility, delete all partitions on that disk,
> then dd if=/dev/zero of=/dev/sda bs=1k count=1 # /dev/sda is the right
disk,
> then REBOOT (yes) and then create your fs directly on /dev/sda, not using
> any partitionning.
>
hmm... yes it already worked (as I wrote) to mkdfs the entire disk but
the block size of the mo is an hardware matter, so I can't fake it to be a
1024 if I really need to do partitioning before mkfs. Anyway, I found out
that partitioning with fdisk behaves badly on every 2k block dev, while
there is an option to tell it to avoid the problem. Thank u anyway
------------------------------
From: "Massimiliano Caovilla" <[EMAIL PROTECTED]>
Subject: where should I put modules to make modprobe find them???
Date: Fri, 24 Nov 2000 12:25:21 +0100
Hello, it's me again...
I feel I'm becoiming an abituee!
I wrote a new kernel module wich is supposed to be the first in a whole new
family of ones, so I wonder if I can put it in a path such as
/lib/modules/mymodules and not in one of the default dirs such as
/lib/modules/misc, so that I can group my modules when I'll have more than
one.
I tryied to mkdir a /lib/modules/something and put it there, but neither
insmod nor modprobe could find it... and I strace'd out that my dir has not
been checked by them.
Do you know of any conf file or whatevere other tricks?
Thank to all & ciao!
------------------------------
From: "Peter T. Breuer" <[EMAIL PROTECTED]>
Subject: Re: where should I put modules to make modprobe find them???
Date: Fri, 24 Nov 2000 13:43:11 +0100
Massimiliano Caovilla <[EMAIL PROTECTED]> wrote:
> I tryied to mkdir a /lib/modules/something and put it there, but neither
> insmod nor modprobe could find it... and I strace'd out that my dir has not
> been checked by them.
> Do you know of any conf file or whatevere other tricks?
No trick is required. Man conf.modules. Add it to the search path.
Peter
------------------------------
From: root <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps,linux.dev.kernel
Subject: extend the blocksize
Date: Fri, 24 Nov 2000 21:25:40 +0800
Most current file systems use only about 4096 bytes blocksize. However,
as I am implementing a video server, I have to extend the blocksize up
to around 512KB. Are there any ways to achieve that ???
Thanks,
Richard.
------------------------------
From: Josef Moellers <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps,linux.dev.kernel
Subject: Re: extend the blocksize
Date: Fri, 24 Nov 2000 14:39:45 +0100
root wrote:
> =
> Most current file systems use only about 4096 bytes blocksize. However,=
> as I am implementing a video server, I have to extend the blocksize up
> to around 512KB. Are there any ways to achieve that ???
Do you really need to increase the blocksize? It's the head movement
that will kill you in video applications, so you just need to make sure
that the data is storen in consecutive blocks or at least in blocks in
close proximity.
Ext2 already does that, however, this may not be enough.
If you think about it, it's the fragmentation which leads to head
movement.
You can always use raw devices (in the sense that there is no
filesystem) or write your own filesystem, perhaps based upon ext2.
-- =
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize (T. Pratchett)
------------------------------
From: Sean <[EMAIL PROTECTED]>
Crossposted-To: linux.dev.kernel
Subject: Block number numbering scheme
Date: Fri, 24 Nov 2000 22:03:40 +0800
What is the numbering scheme of the block number of a SCSI hard disk?
i.e. what is the relationship between the block number and the track,
zone of the hard disk ??
thanks for help,
Sean.
------------------------------
** 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.development.system) 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-Development-System Digest
******************************