Odoo (OpenERP) start-stop-daemon script
29
You are trying to run openerp as root thats why it fails, change:
# Specify the user name (Default: openerp).
USER=root
by
# Specify the user name (Default: openerp).
USER=YOUR_USER_THAT_RUNS_ODOO
Related videos on Youtube
Author by
Hoang Le Viet
Updated on September 18, 2022Comments
-
Hoang Le Viet almost 2 years
I don't want to automatically receive data from firebase on change but receive it only when pressing a button. Any ideas on how to adapt the code below?
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); name = (EditText) findViewById(R.id.editTextTextPersonName); butt = (Button) findViewById(R.id.button); viet = (TextView) findViewById(R.id.textView_viet); butt.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { String var = name.getText().toString(); getdataUser(); } }); } private void getdataUser(){ data_user1.child(var).addValueEventListener(new ValueEventListener() { @Override public void onDataChange(@NonNull DataSnapshot data) { String yy = data.getValue().toString(); viet.setText(yy) } @Override public void onCancelled(@NonNull DatabaseError error) { } }); }
Any ideas are appreciated!
-
Jos almost 9 yearsThe start-stop-daemon itself may have something to log. Edit your script and add something like
>> /var/log/odoo.log
after everystart-stop-daemon
command. Start and stop your process, and see if something shows up in the log. -
Yuri Shtrikker almost 9 yearsI try --logfile ${LFILE} (don't work) and >> ${LFILE} (log is empty) To log file I give chmod 777, and it's don't help
-
Jos almost 9 yearsWhat if you issue the
start-stop-daemon
command yourself? -
Yuri Shtrikker almost 9 yearsif I try to stop it, I see msg: Stopping openerp-server: start-stop-daemon: warning: failed to kill 1204: No such process openerp-server.
-
Jos almost 9 yearsCan you get the server running with
sudo /opt/odoo/openerp-server -c /etc/openerp-server.conf &
? Because that is basically all thestart-stop-daemon
command does when you start the service. -
Yuri Shtrikker almost 9 yearsyea, i can manual start, and all be ok if I do it. process created and log writing. if I need stop him, I use kill command. But if I start from sh (example: sudo su root; sh /etc/init.d/odoo-test start) pid file is creating, but odoo don't work, and i can't stop from sh /etc/init.d/odoo-test stop
-