LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-03-2004, 01:32 PM   #1
Darktyco
Member
 
Registered: Aug 2003
Location: michigan
Distribution: slackware
Posts: 59

Rep: Reputation: 15
X autostart programs on userless sytem?


I have a very minimal linux distro I've put together that has no login program or users at all. I'd like to have a certain program of mine loaded automatically when X is started, but since I have no users, where should my .xinitrc file be placed for this to happen? Or is there another file I must edit instead of .xinitrc?

Thanks
 
Old 08-03-2004, 03:00 PM   #2
nhs
Member
 
Registered: Aug 2003
Location: Edinburgh, Scotland
Distribution: Gentoo
Posts: 246

Rep: Reputation: 30
You must be running as some user. It just doesn't have a name or home directory. The UID is probably 0 so add a line to (or create) /etc/passwd:

root::0:0:superuser:/root:/bin/bash

This will define root's home directory to be /root which is where you should put .xinitrc.
 
Old 08-03-2004, 03:37 PM   #3
Darktyco
Member
 
Registered: Aug 2003
Location: michigan
Distribution: slackware
Posts: 59

Original Poster
Rep: Reputation: 15
Well, I gave it a shot but it didn't work. Are there any other files X uses that aren't user dependant?

Its probably worth mentioning that I'm using /usr/X11R6/bin/X instead of startx to load up xfree. I'm using X because it has the -allowMouseOpenFail option that lets it load even when there is no mouse (the system I'm working on has no mouse.) If there is some way to let X load up without a mouse using the startx command, then its possible your solution might work.

Last edited by Darktyco; 08-03-2004 at 03:52 PM.
 
Old 08-03-2004, 03:52 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911
With the information you provided it's impossible
to assess the situation :)

What exactly is the boot-process doing?
E.g., what happens after rc.local? Are you
booting into init 3 (4,5), which actions are
assigned to that in /etc/inittab?
.xinitrc will be evaluated it the user types
startx on the prompt, .xsession if you use
e.g. kdm with an automatic login.


Cheers,
Tink
 
Old 08-03-2004, 04:03 PM   #5
Darktyco
Member
 
Registered: Aug 2003
Location: michigan
Distribution: slackware
Posts: 59

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by Tinkster
With the information you provided it's impossible
to assess the situation

What exactly is the boot-process doing?
E.g., what happens after rc.local? Are you
booting into init 3 (4,5), which actions are
assigned to that in /etc/inittab?
.xinitrc will be evaluated it the user types
startx on the prompt, .xsession if you use
e.g. kdm with an automatic login.


Cheers,
Tink
I'm using the BusyBox init with a simple inittab that I wrote myself. BusyBox init has no runlevels. Besides basic system configuration the inittab file only starts up an ash shell.

I can't use startx unless I find a way for it to load X without a mouse. I start the server using "X -allowMouseOpenFail" so it still loads, but then it doesn't use /etc/X11/xinit/xinitrc. I need to find a solution to either one
 
Old 08-03-2004, 04:22 PM   #6
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911
Add
Code:
       Option "AllowMouseOpenFail" "true"
to the server-section of your
XF86Config ...



Cheers,
Tink
 
Old 08-03-2004, 04:31 PM   #7
Darktyco
Member
 
Registered: Aug 2003
Location: michigan
Distribution: slackware
Posts: 59

Original Poster
Rep: Reputation: 15
Ah, thank you, everything is in order now
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to execute root-privilege programs in KDE autostart? rylan76 Linux - Software 3 07-31-2005 05:40 AM
autostart programs at login asgari22 Fedora 7 01-31-2005 05:12 PM
Autostart Programs (Xscreensaver) When Starting Blackbox Ian Linux - Software 0 05-09-2004 04:05 PM
Sytem Resources timcrafton Linux - Hardware 3 01-18-2004 07:11 AM
autostart programs mcd Slackware 1 09-12-2003 05:58 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:23 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration