OS type and version
So I wanted to do a simple use of API, clone-domain, so i can run some tests on a site before going live.
When running ‘virtualmin clone-domain …’ I get command not found
virtualmin help give command not found
Event when looking, can see the scripts (in /usr/share/webmin/virtual-server).
seen both of these:-
Our command line API for both virtualmin and webmin seems to be missing entirely. I ran a search (find / -name "filename.pl") for three separate perl scripts that I knew were included in the command line API, but they were nowhere to be found. Do I need to manually install it, or what?
None seem to apply.
I am on GPL (small but growing charity that can’t quite justify, just yet, the cost). but believe this API command should work under GPL?
Any help appreciated
Um, I don’t have Webmin under /usr/share on any of my servers. Did you install Virtualmin via the automated install script?
Automated Virtualmin Installation – Virtualmin.
To use the command line API, you issue the command:
Issuing the command above from the command line will give you a list of commands, and help you understand how to use those commands.
If you have specific questions, feel free to ask, I use the API quite often to automate tasks.
*** Affordable, Reliable Virtualmin Support
Yes it was installed via script about a year ago- all went fine, no problems.
Yes, as per my post, I have been using virtualmin command.
I did find now the GUI version of clone-domain, and that worked fine. But API commands wont work.
I’ll setup a test install and see if I can replicate the issue. It’s my understanding the API and GUI share most of if not all the same code, so both should work without issue. The GUI does do a lot of the heavy lifting like providing the required fields and values, perhaps when executed on CLI you are missing something.
so do you get the command list when you type in virtualmin
Perhaps, something went wrong?
To solve this, simply remove
/usr/sbin/virtualmin file by running
rm -f /usr/sbin/virtualmin comman, then go to Virtualmin UI and re-check configuration (by clicking on
System Settings -> Re-Check Configuration link) to regenerate Virtualmin API helper command.