NocoDB on Truenas

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
The syntax is service nocodb start, not service start nocodb.
 

hocus

Dabbler
Joined
Nov 18, 2022
Messages
11
The syntax is service nocodb start, not service start nocodb.
Yes, I use:

root@nocodb:~ #
root@nocodb:~ # service nocodb start
env: /usr/local/etc/rc.d/nocodb: No such file or directory
root@nocodb:~ #

I made mistake in this post.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
You need to create that script as documented in step 7 of the instructions you linked.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Please post the output of ls -l /usr/local/etc/rc.d inside your jail.
 

hocus

Dabbler
Joined
Nov 18, 2022
Messages
11
Please post the output of ls -l /usr/local/etc/rc.d inside your jail.

Code:
root@nocodb:~ #
root@nocodb:~ #
root@nocodb:~ #
root@nocodb:~ #
root@nocodb:~ #
root@nocodb:~ #
root@nocodb:~ # ls -l /usr/local/etc/rc.d
total 14
-rwxr-xr-x  1 root  wheel   593 Apr 22 04:55 git_daemon
-rwxr-xr-x  1 root  wheel   589 May  2 11:36 nocodb
-rwxr-xr-x  1 root  wheel  3276 Apr 23 02:45 postgresql
root@nocodb:~ #
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Next: head /usr/local/etc/rc.d/nocodb
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
That looks all fine. So something in that script does not work as intended. One of the best ways to debug shell scripts is this:
sh -x /usr/local/etc/rc.d/nocodb start

The last couple of lines of the output will probably be sufficient to spot the problem.
 

hocus

Dabbler
Joined
Nov 18, 2022
Messages
11
That looks all fine. So something in that script does not work as intended. One of the best ways to debug shell scripts is this:
sh -x /usr/local/etc/rc.d/nocodb start

The last couple of lines of the output will probably be sufficient to spot the problem.
I get:
Code:
root@nocodb:~ # sh -x /usr/local/etc/rc.d/nocodb start
+ $'\r'
: not foundetc/rc.d/nocodb:
+ $'\r'
: not foundetc/rc.d/nocodb:
+ . $'/etc/rc.subr\r'
: No such file or directory
root@nocodb:~ #
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
You probably edited the file on Windows and created a superfluous carriage return character at the end of each line. You need to use one of the Unix editors while logged in via an SSH terminal window, then paste the file into that and save.

If you don't know/like vi, there's the ee ("easy editor") or you could pkg install nano and use that.
 

hocus

Dabbler
Joined
Nov 18, 2022
Messages
11
You probably edited the file on Windows and created a superfluous carriage return character at the end of each line. You need to use one of the Unix editors while logged in via an SSH terminal window, then paste the file into that and save.

If you don't know/like vi, there's the ee ("easy editor") or you could pkg install nano and use that.
Wow. Its work... I think much easier create on windows and copy via FTP... Thanks :)
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,504
I think much easier create on windows and copy via FTP.
If you want to do that, you need to use an editor that supports Unix line endings. Notepad doesn't. Notepad++ and VSCode do.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Wow. Its work... I think much easier create on windows and copy via FTP... Thanks :)
If you want to do that, you need to use an editor that supports Unix line endings. Notepad doesn't. Notepad++ and VSCode do.
Or use ASCII mode for your FTP transfer - that will convert on the fly. These protocols are really old ... :wink:
 
Top