How to run JaSFtp as a Service on Linux?

Discuss Mac, Windows, Linux, Unix platform specific issues

How to run JaSFtp as a Service on Linux?

Postby melvin » Thu Jul 20, 2006 1:15 pm

How to automate the run of JaSFtp on Linux after rebooting the server?
(Posted originally by Mshamsan)
Last edited by melvin on Thu Jul 27, 2006 8:27 am, edited 1 time in total.
melvin
Site Admin
 
Posts: 979
Joined: Thu May 25, 2006 10:20 am
Location: Santa Barbara, california

Postby melvin » Thu Jul 20, 2006 1:26 pm

This is a very good question. This answer applies to Version 8.x-9.x only.

The software consists of the user interface and an Engine which runs tasks and schedules. You should setup the Engine to start during reboot.

This procedure is detailed and tested for RedHat Linux. The procedure will be similar, but may not be exactly the same on your unix system:
1) login as root and backup the following file:
/etc/rc.d/rc.local

2) Edit the file rc.local and add the following lines to the end of the file:
cd /../../hitek9 (i.e. Automize or JaSFtp folder)
jre/bin/java -Xrs -cp .:help:jh.jar:mail.jar:activation.jar:net.jar:jakoro.jar:maverick-all.jar:sinetfactory.jar:bsh.jar:hitek9.jar com.hitek.engine.Engine &

OR: if you installed the java machine separately, use
java -Xrs -cp .:help:jh.jar:mail.jar:activation.jar:net.jar:jakoro.jar:maverick-all.jar:sinetfactory.jar:bsh.jar:hitek9.jar com.hitek.engine.Engine &

3) Save the file.

4) IMPORTANT: First run a test script file containing the above 2 lines of code manually from the command line. Confirm that the engine starts running.

5) VERY IMPORTANT: Also, ensure that the command prompt is returned. The & at the end of the launch command makes sure that the scheduler engine runs in the background. This makes sure that your system will not hang on startup waiting for scheduler engine to return.
Last edited by melvin on Thu Apr 14, 2011 10:23 pm, edited 2 times in total.
melvin
Site Admin
 
Posts: 979
Joined: Thu May 25, 2006 10:20 am
Location: Santa Barbara, california

Postby melvin » Thu Jul 20, 2006 2:05 pm

I guess that you do not see the process as a normal user is because the engine is started as root. While logged on as normal user, do you have any problems adding or deleting tasks or running tasks etc..? I do not remember having any problems or any users reporting problems while doing this?
melvin
Site Admin
 
Posts: 979
Joined: Thu May 25, 2006 10:20 am
Location: Santa Barbara, california

Postby melvin » Fri Jul 28, 2006 5:09 pm

Forgot something: to prevent the engine from shutting down when you logoff, you should add the -Xrs switch:

java -Xrs -cp .:help:jh.jar:mail.jar:activation.jar:net.jar:jakoro.jar:maverick-all.jar:sinetfactory.jar:bsh.jar:hitek9.jar com.hitek.engine.Engine &
melvin
Site Admin
 
Posts: 979
Joined: Thu May 25, 2006 10:20 am
Location: Santa Barbara, california


Return to Platform specific issues

Who is online

Users browsing this forum: No registered users and 1 guest

cron