LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-03-2002, 12:01 PM   #1
gco10996
LQ Newbie
 
Registered: Oct 2002
Location: New Windsor, NY
Distribution: Red Hat, Slackware, Smoothwall, Fedora, Mandrake, *BSD
Posts: 20

Rep: Reputation: 0
Question This worked in RH 7.0, but NG in 8.0?


We're replacing some old PII boxes Running RH 7.0 with new P4 laptops, Running Win 2K/RH 8.0. dual boot)
The RH systems have one purpose in life -- to allow unfettered Web access (via cable modem/80211b -- which works GREAT in RH 8.0!) for the purpose of downloading IA tools to a zip drive, to be used in a Lab environment.
The old RH 7.0 systems were set up (via /etc/profile) to allow all but a selected few users access to NOTHING but their home directories (which was /mnt/zip, and Netscape (which launched upon login). After the user exited Netscape, the zip cartridge ejected and the user was logged out.
It seems I can make NONE of this happen in RH 8.0! I can't make /mnt/zip ANYONE's home dir, and trying to launch ANYTHING upon login results in gconf errors, xsession errors, or no keyboard response, should I actually get the browser to launch.
I've tried this in /etc/profile, ~/.bash_profile, xinitrc, Xresources, with default levels of both 3 and 5
I'm using GNOME as the default GUI, and Mozilla as the browser. (I've also tried this with Galeon, to no avail).

Any secrets/insights?
 
Old 11-03-2002, 03:45 PM   #2
adam_boz
Member
 
Registered: Jul 2002
Location: Santa Cruz, CA
Distribution: lfs
Posts: 538

Rep: Reputation: 30
hmm.... the home directories are specified in /etc/passwd, see if you can do anything w/ that.

I think that you can tell gnome what to open when it starts... can't you?

if not, try putting a line like this in ~/.xinitrc :

exec netscape &

******************** before it calls gnome

Are any of the systems still running rh7? if yes, browse around and see how it is configured (groups, logon, whatever). I can't think of how to make it eject and logoff when you close netscape, but there must be a way to do it.

-Adam

 
Old 11-03-2002, 05:08 PM   #3
gco10996
LQ Newbie
 
Registered: Oct 2002
Location: New Windsor, NY
Distribution: Red Hat, Slackware, Smoothwall, Fedora, Mandrake, *BSD
Posts: 20

Original Poster
Rep: Reputation: 0
Eject & logoff are/were the easy part -- just a couple of lines at the end of ~/.bash_profile.
Mounting the zip as home dir, I've just about given up on.

the old /etc/passwd file has nothing unusual in it . . . the home dir portion of each line simply says /mnt/zip . The app launch and logout commands are in /etc/profile, with an if/fi clause to determine whether to run the netscape/logout script, depending on who's logging in.
I figured using ~/.bash_profile would be cleaner.

I'd also discovered that the gnome desktop launches AFTER the

mozilla &

line.
If I can only get the browser to automatically launch SOMEHOW. I can work around the rest. Also, I've tried other GUI apps (just for comparison purposes -- Office Org apps, Galeon . . . no change).

So, what I need is a way to tell GNOME to launch an application automatically once it's up, and then to pass control back to ~/.bash_profile.
Or someting close enough to that.

What's REALLY frustrating is that having an app launch automatically is soooo easy in That-operating-system-which-shall remain-nameless -- howcum evidently not so anymore in RH?????
 
Old 11-03-2002, 05:31 PM   #4
adam_boz
Member
 
Registered: Jul 2002
Location: Santa Cruz, CA
Distribution: lfs
Posts: 538

Rep: Reputation: 30
that's right... the "exec mozilla &" should appear before the "exec gnome" in .xinitrc.

I don't use gnome, but I though that there was a "startup" folder in there just like that one other os :-)

If the home dir is /mnt/zip, you could put something like this in ~/.bash_profile

if [ -z $(mount | grep /mnt/zip) ]; then
mount /dev/zip /mnt/zip
endif

that'll check if /mnt/zip is in the output of mount, and if not... it'll mount it. (replace /dev/zip by whatever it's real device name is)
 
Old 11-04-2002, 01:27 PM   #5
gco10996
LQ Newbie
 
Registered: Oct 2002
Location: New Windsor, NY
Distribution: Red Hat, Slackware, Smoothwall, Fedora, Mandrake, *BSD
Posts: 20

Original Poster
Rep: Reputation: 0
using ~/.xinitrc yields the same results -- the browser launches, but with no title bar or kybd response.

I can get app to launch via Start Here/preferences/extras/session

but then ~/.bash_profile loses control of the system and exiting the browser returns the user to the desktop.

And, here's an excerpt from the original RH 7.0 /etc/profile: (Default Run Level is 3)


if [ `id -u` -ne 0 ]; then
echo Starting Netscape ...
sleep 3
xinit -e netscape -geometry 1024x760-1+0
echo Deleting files in /tmp...
cd /tmp
\rm -r *
echo
echo Make sure you secure your Zip Drive...
sleep 3
eject zip
logout
fi
/bin/bash



This would launch the browser (In this case netscape vs mozilla), eject the Zip and log the user out
upon exiting the browser.
This would apply to any non-root user.

And, as above, trying this in /etc/profile or ~/.bash_profile results in a no-titlebar, keyboard-impaired application. But exiting (the mouse still works) causes the zip to eject and logout, just like we want it to.

Sorry If I seem to be saying the same thing over and over in a repetitively redundant fashion, but I'm getting a bit punch drunk from chasing this thing for about 10 days now . . . more threads, HOWTOs and man pages than I care to count.
 
Old 11-04-2002, 02:30 PM   #6
adam_boz
Member
 
Registered: Jul 2002
Location: Santa Cruz, CA
Distribution: lfs
Posts: 538

Rep: Reputation: 30
I don't know if this will still disreguard what's in ~/.bash_profile, but it's something to try:

In kde, there was an option to "save session" when you exited (I'm sure that there is something similar in gnome)

log in as the user, open up mozilla, and upon exit, save the session. Then go in as root and make the configuration file readable (maybe even executable) to the user, but not writable... that way, they will start up w/ mozilla every time and not be able to change it.

I'll get back if I can think of anything else

good luck

-Adam
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
who had ever worked with khotkeys? phoenix7 Linux - Hardware 4 10-03-2007 04:09 PM
hplip have not worked :( mbt Linux - Hardware 2 12-03-2005 10:49 AM
9.3 worked... but now it doesn't? Agizor SUSE / openSUSE 11 04-26-2005 04:52 PM
Have they worked out wireless G JROCK1980 Linux - Wireless Networking 1 05-08-2004 05:09 PM
supermount worked ever for anyone? ybc Mandriva 5 12-22-2003 07:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration