Project Home
Project Home
Trackers
Trackers
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Phindows doesn't start Photon when using initial command to start after login in passwd file: (7 Items)
   
Phindows doesn't start Photon when using initial command to start after login in passwd file  
I am using QNX 4.24 server with Phindows 2.0 and Photon since 2001 without any problem. For a specific user, I use to 
autostart an application immediately after a succesfull login (in this case "sac" utility in passwd file)

jd213:x:105:100:John Doe:/home/jd213:/usr/bin/sac

I installed QNX 4.25 (last 2011 installation CD bundle) on a new server with creating the same user jd213. If I use /bin
/sh in passwd file, it is OK, Photon is started when I logged in from Phindows. Unfortunately this autostart is not 
working anymore when I try any other autostart executables like /usr/bin/sac when I login from Phindows. Phindows Window
 is closing right away without charging Photon. However when I try to login from telnet, "sac" execution is working, 
Photon is charged after Phindows login. Curious isn't it ?

Does any of you have ever this problem? If yes, what could be the solution

Thank you
Re: Phindows doesn't start Photon when using initial command to start after login in passwd file  
I just realise that when I copy /qnx4/photon (v1.13) over /qnx4/photon (v1.14) it solve the problem. But what could be 
wrong in Photon v1.14 that create this issue ? a config file somewhere or something else ?

If someone know the answer...
Re: Phindows doesn't start Photon when using initial command to start after login in passwd file  
Hi Louis,

The phlogin utility executes shell command from /etc/passwd to launch script to open new session. This fails with sac 
utility.

To automatically start an application immediately after launch Photon add it to $HOME/.photon/phapps:

pterm /usr/bin/sac &

or

phsac &

Respectfully,
Oleg

04.09.2013, в 18:37:33, Louis Francoeur написал:

> I just realise that when I copy /qnx4/photon (v1.13) over /qnx4/photon (v1.14) it solve the problem
. But what could be wrong in Photon v1.14 that create this issue ? a config file somewhere or something else ?
> 
> If someone know the answer...
> 
> 
> 
> _______________________________________________
> 
> QNX4 Community Support
> http://community.qnx.com/sf/go/post104808
> To cancel your subscription to this discussion, please e-mail qnx4-community-unsubscribe@community.qnx.com

Re: Phindows doesn't start Photon when using initial command to start after login in passwd file  
Hi Oleg,

What you explained is true, I can use $HOME/.photon/phapps utility. But I still have a problem:
I want to be able to start a program even if I access from Photon or from Telnet with the same login.

Now with $HOME/.photon/phapps utility active, my program is started from Photon but not from Telnet. If I add my program
 in /etc/passwd (for example: jd213:x:105:100:John Doe:/home/jd213:/bin/program), Telnet is working fine but not Photon 
anymore (close the Window right away).

Is there a way to be able to automaticly start a program even from Photon or Telnet without creating 2 different logins 
in Photon 1.14 (curiously, it was working in Photon 1.13)?

Thank you
Re: Phindows doesn't start Photon when using initial command to start after login in passwd file  
Hi Louis,

New version of software should be handier but I noticed that even small update may lead into trouble. :)

One possible way to get that you ask is adding the following script (fake_sac) instead of sac in /etc/passwd:

----
#!/bin/sh

if [ $1"m" != "m" ]; then
    exec /bin/sh "$@"
else
    exec /usr/bin/sac
fi
----

Respectfully,
Oleg



16.09.2013, в 16:53:52, Louis Francoeur написал(а):

> Hi Oleg,
> 
> What you explained is true, I can use $HOME/.photon/phapps utility. But I still have a problem:
> I want to be able to start a program even if I access from Photon or from Telnet with the same login.
> 
> Now with $HOME/.photon/phapps utility active, my program is started from Photon but not from Telnet. If I add my 
program in /etc/passwd (for example: jd213:x:105:100:John Doe:/home/jd213:/bin/program), Telnet is working fine but not 
Photon anymore (close the Window right away).
> 
> Is there a way to be able to automaticly start a program even from Photon or Telnet without creating 2 different 
logins in Photon 1.14 (curiously, it was working in Photon 1.13)?
> 
> Thank you
> 
> 
> 
> _______________________________________________
> 
> QNX4 Community Support
> http://community.qnx.com/sf/go/post105128
> To cancel your subscription to this discussion, please e-mail qnx4-community-unsubscribe@community.qnx.com

Re: Phindows doesn't start Photon when using initial command to start after login in passwd file  
Hi again Oleg,

Now this issue is solved with your last suggestion "fake_sac". I am very happy :)

Thank you very much
Re: Phindows doesn't start Photon when using initial command to start after login in passwd file  
Louis

I'm glad to hear it. Making people happy is my work. :)

Respectfully,
Oleg

16.09.2013, в 18:08:33, Louis Francoeur написал:

> Hi again Oleg,
> 
> Now this issue is solved with your last suggestion "fake_sac". I am very happy :)
> 
> Thank you very much
> 
> 
> 
> _______________________________________________
> 
> QNX4 Community Support
> http://community.qnx.com/sf/go/post105131
> To cancel your subscription to this discussion, please e-mail qnx4-community-unsubscribe@community.qnx.com