Project

General

Profile

No script with id create-node

chenli li
Added about 4 years ago

I have copied all scripts the files to the scripts/admin/pubsub in Tigase XMPP Server instance directory.

but when i execute the command

bin/tclmt.sh -u admin@example.com -p admin123 remote pubsub.example.com create-node example admin@example.com leaf

it returned the result:

Create empty DB.

No script with id create-node


Replies (11)

(1)

Added by Wojciech Kapcia TigaseTeam about 4 years ago

Please make sure that the script is loaded (in the logs) and available from clients (for example Psi).

Added by chenli li about 4 years ago

it is unavailable in Psi.

how to change the stting to make it can load those scripts.

(1)

Added by Wojciech Kapcia TigaseTeam about 4 years ago

It should load them automatically. Please look at the log and look entries regarding loading this particular script. you can also try putting the script directly in @scripts/admin/@.

Added by chenli li about 4 years ago

I have already put them in the scripts/admin/ directory. But it still have this problem.

Added by chenli li about 4 years ago

When execute the CreateNode command the server can return result,but only finish button and cancel button can be used in psi.

result.xml (4.11 KB) result.xml result returned by server
(1)

Added by Wojciech Kapcia TigaseTeam about 4 years ago

chenli li wrote:

I have already put them in the scripts/admin/ directory. But it still have this problem.

chenli li wrote:

When execute the CreateNode command the server can return result,but only finish button and cancel button can be used in psi.

I assume this means that the script was finally loaded?

Finish button is used to accept the form and create the node.

Added by chenli li about 4 years ago

Those scripts have been loaded,but when using tclmt to execute command it still returned the result

Create empty DB.

No script with id create-node

Moreover,in the psi,after click the finish button the psi reloaded the same page, still only finish button and cancel button can be used.

(1)

Added by Abhinav Gupta about 3 years ago

Hi,

I am facing the same issue.

Can please some one explain the syntax of the command,

bin/tclmt.sh -u admin@example.com -p admin123 remote pubsub.example.com create-node example admin@example.com leaf

what are remote and pubsub.example.com in above command

and where exactly the script CreateNode.groovy should be present, in ~/tclmt-1.0.0-SNAPSHOT/scripts or somewhere else.

Thanks

Abhinav

Added by Daniel Wisnewski IoT 1 Cloud about 3 years ago

The breakdown is as follows:

-u [JID of user wanting to make comand]

-p [password of JID]

remote [server is remote from script location]

pubsub.example.com [This is the location of pubsub component, typically it is pubsub.domain.com, but can be named differently if comp-name is set to something else]

create-node [name of script to be run]

example [name of node]

admin@example.com [Owner of node]

leaf [Type of node, in this case items will be published to the node, there is also collection which has a collection of other nodes]

As for the location of the scripts, they should be in scripts/admin/pubsub

http://docs.tigase.org/tigase-server/snapshot/Administration_Guide/html/#_adhoc_commands

that link should fill in some more detail for you.

(1)

Added by Abhinav Gupta about 3 years ago

Hi Daniel,

Thanks for the reply,

Sorry for the delayed response.

I did as you suggested but i am still facing the same issue.

my domain name is abhinav but when i give the command

bin/tclmt.sh -u admin@abhinav -p admin remote pubsub.abhinav create-node example admin@abhinav leaf

i get unknownhost error for abhinav.(also i have not used ".com " in my domain so i have removed it, please let me know if i have to attach it to the domain as part of some convention.)

so i modified the command to

bin/tclmt.sh -u admin@localhost create-node Operations admin@abhinav leaf (I have also removed the command remote)

I get "no id for create-node error"

although if i try below

bin/tclmt.sh -u admin@localhost remote pubsub.abhinav create-node Operations admin@abhinav leaf

i get "Errors: [remote-server-not-found]"

also tried the same command as above

bin/tclmt.sh -u admin@localhost remote pubsub.abhinav.com create-node Operations admin@abhinav leaf

but got the same error

i get "Errors: [remote-server-not-found]"

Please advise.

Thanks & Regards

Abhinav

Added by Wojciech Kapcia TigaseTeam about 3 years ago

You need to understand the notations (hostname vs VHost/domain) and setup correctly your server. I've checked your logs and you have something like that:

JID (admin address) has the form of the admin@VHost and the VHost/domain is just a name that's configured in the server -- all users should use this domain and if you try connecting user with different domain which is not configured (in --virt-hosts@) then you will get @host-unknown error. Similarly if you try to send message to an address which is not configured on the server then you will get error remote error not found so you should use addresses like @pubsub.VHost@.

Now the second part - the actuall hostname of the machine to which you want to connect / on which Tigase is configured -- in the ideal configuration your VHost should resolve/translate to the IP/hostname of the machine, but it may not be the case (if you are running it locally and using different VHosts for tests) so you can explicitly configure the hostname (machine name) to which you want to connect.

From the above abhinav is not configured as VHost hence the errors.

    (1-11/11)