This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
211
Installation / Re: CWPPRO upgrade
« on: March 18, 2019, 12:06:49 AM »
What results when you access CWP -> Webserver Settings -> Apache Status..??
Regards,
Netino
Regards,
Netino
212
CentOS 7 Problems / Re: named.ca
« on: March 18, 2019, 12:04:14 AM »
Run the following command, at the shell prompt:
... and post the results.
Regards,
Netino
Code: [Select]
# named-checkconf
... and post the results.
Regards,
Netino
213
CentOS 7 Problems / Re: two instances of httpd after update
« on: March 16, 2019, 10:38:00 PM »
There are httpd for virtual hosts, and httpd for cwp, they are not the same.
How have you tried to reinstall the httpd .. ??
Apache for virtual hosts is a customized version, and must be installed as needed and guided by cwp.
Did you tried to rebuild Apache to the same version and settings..??
Regards,
Netino
How have you tried to reinstall the httpd .. ??
Apache for virtual hosts is a customized version, and must be installed as needed and guided by cwp.
Did you tried to rebuild Apache to the same version and settings..??
Regards,
Netino
214
CentOS 7 Problems / Re: HTTP Test page on IP Change
« on: March 16, 2019, 10:32:42 PM »
I have never been through this situation, but instead I would first try to see if any IP has been left to change, with the following command:
If you find a file in the list, you would give it a look at the file, and if you really needed to change the IP, you would use the following command:
Regards,
Netino
Code: [Select]
# find /var/named -type f -exec grep -l "XX.XX.XX.218" {} +
# find /usr/local/apache/conf* -type f -exec grep -l "XX.XX.XX.218" {} +
If you find a file in the list, you would give it a look at the file, and if you really needed to change the IP, you would use the following command:
Code: [Select]
# find /var/named -type f -exec grep -l "XX.XX.XX.218" {} + | xargs -i perl -pi -e "s/XX.XX.XX.218/XX.XX.XX.220/g" {}
# find /usr/local/apache/conf* -type f -exec grep -l "XX.XX.XX.218" {} + | xargs -i perl -pi -e "s/XX.XX.XX.218/XX.XX.XX.220/g" {}
Regards,
Netino
215
CentOS 7 Problems / Re: Problem mysql
« on: March 16, 2019, 10:18:38 PM »
1) the correct script for execution is
2) Did you check your MySQL root password in: "/usr/local/cwpsrv/htdocs/resources/admin/include/db_conn.php" and "/root/.my.cnf" files, if match..??
Regards,
Netino
Code: [Select]
# sh /scripts/restart_cwpsrv
not "sh / scripts / restart_cwpsrv".2) Did you check your MySQL root password in: "/usr/local/cwpsrv/htdocs/resources/admin/include/db_conn.php" and "/root/.my.cnf" files, if match..??
Regards,
Netino
216
Backup / Re: Connection Failed
« on: March 16, 2019, 10:12:00 PM »Should I have to click "Generate New Key" Button under the "Remote Backup Settings" or manually copy the /root/.ssh/id_rsa to the /root/.ssh/backup/id_rsa
The SSHD server, in the default configuration, will read the key only in the '/root/.ssh/' directory.
217
Backup / Re: Connection Failed
« on: March 16, 2019, 10:08:47 PM »One last thing, I would like to know that this backup contains all the user files and content from the main server?
No, just for virtual hosts.
If you need backup for the main server, you will need to hardcode it.
218
How to / Re: How to Automate User Account creation?
« on: March 16, 2019, 09:53:53 PM »
The fields to "add" function to add accounts using API are the following:
=================================================
key: Key authorized by Api administrator
action: add
domain: main domain associated with the account
user: username to create
pass: Password for the account
email: Email Address of the account owner
package: Create account with package
inode: number of inodes allowed
limit_nofile: limit_nofile
server_ips: server_ips
=================================================
Ps:
1) Is not possible to preserve Ids from other server with API. Only hardcoded is possible, although not recommended.
2) you don't have passwords in your data file, but passwords are mandatory to the API.
So, you can add a field to fulfil the password field, or change it to your taste.
3) max lenght of username field is assumed 8 characters lenth, of valid characters to unix usernames.
So, suppose you have your data accounts in a file name 'dataaccounts.csv' in current directory.
Save and run the following script:
This script was written in bash, but you can write it too in php, as suggested in CWP API manager.
=================================================
key: Key authorized by Api administrator
action: add
domain: main domain associated with the account
user: username to create
pass: Password for the account
email: Email Address of the account owner
package: Create account with package
inode: number of inodes allowed
limit_nofile: limit_nofile
server_ips: server_ips
=================================================
Ps:
1) Is not possible to preserve Ids from other server with API. Only hardcoded is possible, although not recommended.
2) you don't have passwords in your data file, but passwords are mandatory to the API.
So, you can add a field to fulfil the password field, or change it to your taste.
3) max lenght of username field is assumed 8 characters lenth, of valid characters to unix usernames.
So, suppose you have your data accounts in a file name 'dataaccounts.csv' in current directory.
Save and run the following script:
Code: [Select]
#!/bin/sh
# Change the following variables
value_key="[YOUR KEY HERE]"
default_password="[DEFAULT PASSWORD]"
password="[PASSWORD]"
your_server="[YOUR-SERVER]" # IP address or domain
while IFS="," read id username domain ip_address email setup_date package backup; do
status=$(curl --data "key=${value_key}" \
--data "action=add" \
--data "domain=${domain}" \
--data "user=${username}" \
--data "pass=${default_password}" \
--data "email=${email}" \
--data "package=${package}" \
--data "inode=0" \
--data "limit_nofile=0" \
--data "server_ips=${ip_address}" \
https://${your_server}:2304/v1/account)
if [[ ${status} -eq 28 ]]; then
echo "... ... Timeout accessing URL: https://${your_server}:2304/v1/account ... !!!"
echo "Timeout accessing URL https://${your_server}:2304/v1/account: More than $timeout seconds trying to access." | \
elif [[ ${status} -eq 6 ]]; then
echo "... ... Error accessing URL: https://${your_server}:2304/v1/account ... !!!"
echo "Error accessing URL https://${your_server}:2304/v1/account: The domain host could not be resolved." | \
elif [[ ${status} -eq 51 ]]; then
echo "... ... Error accessing URL: https://${your_server}:2304/v1/account ... !!!"
error = "Error accessing URL https://${your_server}:2304/v1/account: Could not communicate securely with server:"
error = "${error} The requested domain does not match the server's certificate."
echo ${error}
elif [[ ${status} -gt 0 ]]; then
error = "Error code ${status} has been returned"
echo "${error}"
fi
done < dataaccounts.csv
This script was written in bash, but you can write it too in php, as suggested in CWP API manager.
219
MySQL / Re: It's possible to upgrade mariadb to 10.3+?
« on: March 15, 2019, 04:48:41 AM »
The upgrade of mariadb is the most sensible service to upgrade, because you need to deal with installed databases.
The PHP switcher in CWP can install and upgrade new PHP versions to you.
Use it periodically.
The Apache server is customized too, and must be upgraded too in a guided way, when new CWP versions asks.
To the remaining default services, you can use just the following command daily:
The PHP switcher in CWP can install and upgrade new PHP versions to you.
Use it periodically.
The Apache server is customized too, and must be upgraded too in a guided way, when new CWP versions asks.
To the remaining default services, you can use just the following command daily:
Code: [Select]
# yum update
220
Information / Re: CWP email send on login
« on: March 15, 2019, 04:38:06 AM »
Login in what services..??
221
How to / Re: How to Automate User Account creation?
« on: March 15, 2019, 04:35:28 AM »
What fields and what format you have in your .csv file..??
222
Installation / Re: Adding CAA record on CWP
« on: March 15, 2019, 04:33:29 AM »
Edit your zone file in '/var/named' directory.
For example, for a "example.com" domain, the file '/var;named/domain.com.db'.
And add the following at the final of that file, for exemple to the Let’s Encrypt certificate authority,:
If you want to allow Let’s Encrypt for wildcard certificates, then you can use issuewild:
Save the changes, and restart named:
(for CentOS 7)
(for CentOS 6.*)
For example, for a "example.com" domain, the file '/var;named/domain.com.db'.
And add the following at the final of that file, for exemple to the Let’s Encrypt certificate authority,:
Code: [Select]
example.com. CAA 0 issue "letsencrypt.org"
If you want to allow Let’s Encrypt for wildcard certificates, then you can use issuewild:
Code: [Select]
example.com. CAA 0 issuewild "letsencrypt.org"
Save the changes, and restart named:
(for CentOS 7)
Code: [Select]
# systemctl restart named
(for CentOS 6.*)
Code: [Select]
# service named restart
223
CentOS 6 Problems / Re: Domain Pointing to wrong folder
« on: March 13, 2019, 04:25:35 AM »
You can have a DNS resolving problem, or a apache configuration problem.
But as you are using clodflare, may be you have a apache configuration problem.
Start testing if your domain is resolving correctly to your server.
Run inside your server:
If pointed to your server, check apache logs.
If no, fix you DNS problem.
When you assure your domain is resolving to your server, you can check if apache is serving your pages.
You must check your logs:
If they are served, you can fix the problems as pointed in your logs.
Regards,
Netino
But as you are using clodflare, may be you have a apache configuration problem.
Start testing if your domain is resolving correctly to your server.
Run inside your server:
Code: [Select]
# host domain.com
If pointed to your server, check apache logs.
If no, fix you DNS problem.
When you assure your domain is resolving to your server, you can check if apache is serving your pages.
You must check your logs:
Code: [Select]
/usr/local/apache/logs/error_log
/usr/local/apache/logs/access_log
/usr/local/apache/domlogs/domain.com.error.log
/usr/local/apache/domlogs/domain.com.log
If they are served, you can fix the problems as pointed in your logs.
Regards,
Netino
224
Installation / Re: Adding CAA record on CWP
« on: March 13, 2019, 04:13:11 AM »
Good point.
CWP seems not have CAA record in DNS functions.
CAA records are growing in importance in global internet, as several authorities begin to emerge offering free certificates, posing security problems to domain owners.
May be you have do it only manually, at the moment.
Regards,
Netino
CWP seems not have CAA record in DNS functions.
CAA records are growing in importance in global internet, as several authorities begin to emerge offering free certificates, posing security problems to domain owners.
May be you have do it only manually, at the moment.
Regards,
Netino
225
CentOS 6 Problems / Re: CWP Mail Error
« on: March 13, 2019, 03:15:54 AM »
You can have a broken queue, that could not be managed by CWP in all possibilities, and could need to manually fix the problem.
Follow this tutorial to manage and fix manually you queue, up to fix all of your queue problems:
https://www.wirehive.com/thoughts/5-top-tips-reviewing-postfix-mail-queue/
Naturally, after fix manually, CWP could manage from that on.
Regards,
Netino
Follow this tutorial to manage and fix manually you queue, up to fix all of your queue problems:
https://www.wirehive.com/thoughts/5-top-tips-reviewing-postfix-mail-queue/
Naturally, after fix manually, CWP could manage from that on.
Regards,
Netino