using /etc/rt.local to start EW automatically - Error(?)

38 views
Skip to first unread message

Billy

unread,
Aug 18, 2021, 2:58:38 PM8/18/21
to Earthworm Community Forum
Hi all,

I generally use /etc/rc.local script for having running EW automatically after starting or restarting a server. The mentioned script contains the next lines:

#!/bin/sh -e
su - sysop -c "source /home/sysop/ew/run/params/ew_linux.bash&& startstop &"

In a case for a server with Ubuntu 18.04 LTS after this script has been executed by rc-local service it starts filling the syslog with the next message:

 Press return to print Earthworm status, or
   type restart nnn where nnn is proc id or name to restart, or
   type quit<cr> to stop Earthworm.

and it ends up eating the entire disk space in few hours. It is a madness to have this error(?) which I had not experienced before. In fact, this is still working and starting earthworm automatically in an old ubuntu system. 

Any idea what I could be doing wrong? or maybe I need to update/change something.

As a workaround I modified the script so that the the message  (errors or notifications) are redirected:

su - sysop -c "source /home/sysop/ew/run/params/ew_linux.bash&& startstop > /dev/null 2>&1"

Cheers,

Billy Burgoa Rosso



Minkel, Donald

unread,
Aug 18, 2021, 9:15:48 PM8/18/21
to earthwo...@googlegroups.com

--
--
You received this message because you are subscribed to the Google
Groups "Earthworm Community Forum" group.
 
To post to this group, send an email to earthwo...@googlegroups.com
 
To unsubscribe from this group, send an email to
earthworm_for...@googlegroups.com
 
For more options, visit this group at
http://groups.google.com/group/earthworm_forum?hl=en

---
You received this message because you are subscribed to the Google Groups "Earthworm Community Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to earthworm_for...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/earthworm_forum/2d1ca7a9-9c01-40cf-8a60-ed2eb449a009n%40googlegroups.com.


--
Dr. Donald H. Minkel
Distinguished Professor of Geology
Science Building S-203
SUNY Adirondack
640 Bay Road
Queensbury, NY 12804

Victor Preatoni

unread,
Aug 19, 2021, 8:07:57 AM8/19/21
to Earthworm Community Forum
Hi Billy,

I've moved forward systemd on Ubuntu 20.04 and it's working really nice. Same approach with Winston, with the advantage of deferring services start until dependencies are up and running (eg.: for Winston u need MariaDB up and running). You can also define another user to avoid running Earthworm as root.

This is my systemd Earthworm startup file. You should change directories and environment files according to your installation.


/etc/systemd/system/earthworm.service         
------------------------------------------------------------------
[Unit]
Description             = Earthworm
Wants                   = network.target
After                   = multi-user.target

[Service]
WorkingDirectory        = /opt/earthworm/run/
EnvironmentFile         = /opt/earthworm/run/etc/env_config
ExecStart               = /opt/earthworm/earthworm_7.10/bin/startstop /opt/earthworm/run/params/startstop_unix.d > /opt/earthworm/run/log/earthworm.log>
ExecStop                = /opt/earthworm/earthworm_7.10/bin/pau
ExecReload              = /opt/earthworm/earthworm_7.10/bin/pau; sleep 10; /opt/earthworm/earthworm_7.10/bin/startstop /opt/earthworm/run/params/starts>
StandardOutput          = journal
StandardError           = journal
User                    = earthworm
Group                   = earthworm
UMask                   = 0002

[Install]
WantedBy                = multi-user.target


Then, invoke with sudo systemctl start earthworm command.

Billy Edson Burgoa Rosso

unread,
Aug 23, 2021, 12:38:39 PM8/23/21
to earthwo...@googlegroups.com
Hi Victor and Donald,

Thanks for your help. I will see and test the one that best suits my issue.

Regards,

Billy

--
--
You received this message because you are subscribed to the Google
Groups "Earthworm Community Forum" group.
 
To post to this group, send an email to earthwo...@googlegroups.com
 
To unsubscribe from this group, send an email to
earthworm_for...@googlegroups.com
 
For more options, visit this group at
http://groups.google.com/group/earthworm_forum?hl=en

---
You received this message because you are subscribed to the Google Groups "Earthworm Community Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to earthworm_for...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages