Go Back   maemo.org - Talk > OS / Platform > Maemo 5 / Fremantle
 
Register FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
  #1  
Old 2009-12-01, 16:52
cddiede's Avatar
cddiede cddiede is offline
 
Join Date: Dec 2007
Location: Annapolis, MD
Posts: 1,034
Thanks!: 1,339
Thanked 784 Times in 362 Posts
Default N900 init.d scripts

So, I'm trying to set the X11vnc server to start automatically when the phone boots by creating a startvnc script in /etc/init.d and then sym-linking that to an /etc/rc3.d/S99vnc entry.

Everything is set up and the startvnc script runs just fine when I invoke it manually with:
"/etc/init.d/startvnc start"

However, when I reboot the phone, no vnc processes are running at boot.

I tried copying the symbolic link to /etc/rc5.d and /etc/rcs.d with no luck.

I even tried creating .login and .autostart files with the vnc start command in my user home directory and got nothing...

Am I missing something about the basic run level physics of a Maemo device?
Reply With Quote
  #2  
Old 2009-12-01, 16:57
benny1967's Avatar
benny1967 benny1967 is offline
 
Join Date: Mar 2006
Location: Vienna, Austria
Posts: 3,790
Thanks!: 5,264
Thanked 5,718 Times in 1,546 Posts
Default Re: N900 init.d scripts

I have no N900 and no idea what I'm writing about here - but I have this faint memory that the default runlevel on maemo devices is 2, not 5. Do you see a /etc/rc2.d?
Reply With Quote
  #3  
Old 2009-12-01, 17:05
naabi naabi is offline
 
Join Date: Nov 2009
Location: Helsinki, Finland
Posts: 219
Thanks!: 57
Thanked 94 Times in 60 Posts
Default Re: N900 init.d scripts

Does the device have file /etc/inittab. It should contain the following line with default runlevel specified.

id:2:initdefault:

Don't have the device and my scratchbox is on different machine, but this is a common way in linux distributions.
Reply With Quote
  #4  
Old 2009-12-01, 17:09
cddiede's Avatar
cddiede cddiede is offline
 
Join Date: Dec 2007
Location: Annapolis, MD
Posts: 1,034
Thanks!: 1,339
Thanked 784 Times in 362 Posts
Unhappy Re: N900 init.d scripts

Run level 2, eh?

I hadn't heard that one, but what the hell.

So, I copied the start sym-link to /etc/rc2.d and rebooted.

Still no vnc processes running at boot.
Reply With Quote
  #5  
Old 2009-12-01, 17:17
Shanezlar's Avatar
Shanezlar Shanezlar is offline
 
Join Date: Oct 2009
Location: Allemagne
Posts: 38
Thanks!: 57
Thanked 67 Times in 15 Posts
Default Re: N900 init.d scripts

edit: nevermind

Last edited by Shanezlar; 2009-12-01 at 17:19.
Reply With Quote
  #6  
Old 2009-12-01, 17:19
qwerty12's Avatar
qwerty12 qwerty12 is offline
 
Join Date: Sep 2007
Location: Looking at y'all and sighing
Posts: 4,274
Thanks!: 5,528
Thanked 5,358 Times in 1,954 Posts
Default Re: N900 init.d scripts

The N900 uses Upstart, not init.

Make a file in /etc/event.d/.
Reply With Quote
The Following 19 Users Say Thank You to qwerty12 For This Useful Post:
  #7  
Old 2009-12-01, 17:45
cddiede's Avatar
cddiede cddiede is offline
 
Join Date: Dec 2007
Location: Annapolis, MD
Posts: 1,034
Thanks!: 1,339
Thanked 784 Times in 362 Posts
Default Re: N900 init.d scripts

Well, I copied the /etc/event.d/welcome script to a vncstart file and replaced it's echo statement with /usr/bin/x11vnc -forever&

Chmod 777 on /etc/event.d/vncstart and rebooted.

Still no vnc processes running at boot.

Am I missing something in the formatting of an event.d script?
Reply With Quote
  #8  
Old 2009-12-01, 17:47
cddiede's Avatar
cddiede cddiede is offline
 
Join Date: Dec 2007
Location: Annapolis, MD
Posts: 1,034
Thanks!: 1,339
Thanked 784 Times in 362 Posts
Default Re: N900 init.d scripts

To clarify:

My /etc/event.d/vncstart script looks like this:

Start at startup

script
/usr/bin/x11vnc -forever&
end script
Reply With Quote
  #9  
Old 2009-12-01, 17:50
SubCore's Avatar
SubCore SubCore is offline
 
Join Date: Sep 2009
Location: Vienna, Austria
Posts: 850
Thanks!: 1,021
Thanked 626 Times in 320 Posts
Default Re: N900 init.d scripts

Quote:
Originally Posted by cddiede View Post
To clarify:

My /etc/event.d/vncstart script looks like this:

Start at startup

script
/usr/bin/x11vnc -forever&
end script
try
start on startup
(better even "start on X11", since X11vnc needs a running X, although i don't know if X11 is actually exposed as event)

http://upstart.ubuntu.com/getting-started.html
Reply With Quote
The Following 6 Users Say Thank You to SubCore For This Useful Post:
  #10  
Old 2009-12-01, 17:51
mattmull mattmull is offline
 
Join Date: Oct 2009
Posts: 29
Thanks!: 8
Thanked 6 Times in 4 Posts
Default Re: N900 init.d scripts

Does X need to be running before x11vnc is launched?

Edit: SubCore beat me to it
Reply With Quote
Reply


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

Forum Jump


All times are GMT. The time now is 21:24.