Guides and tutorials

Hundreds of tutorials and step by step guides carefully written by our support team.

Swhosting-rpc package

The software package swhosting-rpc is the API that is responsible for communicating and synchronizing the actions performed in SW Panel with your Cloud server.

When you perform any action in SW Panel, it will make a remote procedure call (RPC) to your Cloud requesting the swhosting-rpc program to execute the action.

Installation

To proceed with the installation of swhosting-rpc, we will first add the repository by executing the following commands:

cat >> /etc/apt/sources.list <<EOF
# SWHosting XML RPC
deb http://packages.swhosting.com/serveisweb stable non-free
EOF

Download the public key:

wget -O - http://packages.swhosting.com/serveisweb/swhosting.gpg.key|apt-key add -

Finally, we install:

apt-get install swhosting-rpc

It will show us the list of packages to install, press the letter "y" and "Enter".

All servers with SWPanel use license deployed by SWHosting already have this package installed by default.

Upgrade

If at any time we have to update this package, we execute the following commands:

apt-get update
apt-get install swhosting-rpc

Or if you prefer, you can update all the packages:

apt-get update
apt-get upgrade

Be careful, this operation will update all the packages of your system. Proceed only if you know what you are doing...

Structure

The package generates two directories:

  • Executables: /usr/local/SWHostingRPC/
  • Log and RPC configuration: /etc/swhosting-rpc/

Configuration and checking

We have the following configuration files:

  • RPC Service: /etc/swhosting-rpc/swhostingrpc.yml

    • In this same directory, you will find a sample configuration file: swhostingrpc.yml.sample
  • Log configuration: /etc/swhosting-rpc/log4perl.conf

  • You can know that everything is fine executing the script

/usr/local/SWHostingRPC/sbin/test.pl

If there were an error, it would appear.

IMPORTANT: To edit the configuration files, use spaces and no tabs.

Troubleshooting

  • I have modified the configuration but it does not apply.

    • If the configuration made in the file /etc/swhosting-rpc/swhostingrpc.yml is not applied, check that there is no other file swhostingrpc.yml in /usr/local/SWHostingRPC/. If so, delete it.
  • I run the test and errors appear.

    • Check that the database engine MySQL / MariaDB is not stopped

/etc/init.d/mysql status

- It is possible that you have modified at some point the password of the user "root" or "debian-sys-maint" and this change has not been reflected in the configuration file "swhostingrpc.yml".



> Remember that you can request the intervention of the Systems Engineering Area by opening a ticket for technical action.
Your privacy is important for us
We use our own cookies for the proper functioning of the site. In addition, third-party cookies are used for analytical purposes only. This information is not associated with any person so that personal identifying data is not stored, but is only information that is collected to identify the session, with the aim of facilitating the analysis of the website. You can change your preferences at any time by entering this website again. For more information about our cookie policy you can visit our Cookies. You can press the "Accept and close" button to give us your consent or you can access more detailed information and manage cookies.
Your privacy is important for us
We use our own cookies for the proper functioning of the site. In addition, third-party cookies are used for analytical purposes only. This information is not associated with any person so that personal identifying data is not stored, but is only information that is collected to identify the session, with the aim of facilitating the analysis of the website. You can change your preferences at any time by entering this website again. For more information about our cookie policy you can visit our Cookies. You can press the "Accept and close" button to give us your consent or you can access more detailed information and manage cookies.