Symptoms
-
Unable to open Subscriptions > example.com > Node.JS for newly migrated domain:
PLESK_ERROR: Server Error
500
Error
Call to a member function getPath() on null -
Domain example.com has non-existent nodejs-handler-path:
MYSQL_LIN: MariaDB [psa]> select val from dom_param where param=’ext-nodejs-handlerPath’ and dom_id=(select id from domains where name=’example.com’ limit 1);
+—————————-+
| val |
+—————————-+
| /opt/plesk/node/7/bin/node |
+—————————-+# ls -l /opt/plesk/node/7/bin/node
ls: cannot access /opt/plesk/node/7/bin/node: No such file or directory
Cause
This is a Plesk bug with the Node.JS extension #EXTNODEJS-122 which is going to be fixed in the future updates.
Resolution
As a workaround, re-install Node.js: go to Extensions > My Extensions > Node.js > More > Remove and install it again.
Alternatively, update the database:
-
Connect to the server via SSH
-
Login to the database
# plesk db
-
Modify the nodejs-handler-path to /opt/plesk/node/8/bin/node:
MYSQL_LIN: update dom_param set val=’/opt/plesk/node/8/bin/node’ where dom_id=(select id from domains where name=’example.com’ limit 1) and param=’ext-nodejs-handlerPath’;