
Habra Most recently, I started system administration, about 2 months ago. For this, I immediately apologize for the algorithms implemented in a strange way and, probably, not “absolutely” professionally written code. I want to show you my creation, and ask whether you need to develop it. Although in reality this is not a CP, but a solid bydlokod, nobody needs it, you shouldn’t look under it either.
The panel was originally conceived for personal use, but then I decided to show it to others. So excuse, the installation script will not be to try it will be necessary to do everything with pens, according to the instructions that I provide below.
The panel works on a separate port using SSL. Tested on
FreeBSD 8.1-RELEASE i386 . Recens CP requires Apache 2.2 and suPHP to work.
We proceed to the setting.
- It is desirable to create a new user in the system (with the adduser command), with a separate home directory. I have this / home / recens
- Download ( sourceforge.net/projects/recens/files/recens-beta.zip/download ) and unpack the archive into the directory public_html
- The panel works with ipfw and executes various commands that need a super user, therefore you need to do:
chown -R root:wheel /usr/home/recens/data/public_html
- You also need to change the suPHP config. Find lines in /usr/local/etc/suphp.conf:
; Minimum UID min_uid=80 ; Minimum GID min_gid=80
and change them to
; Minimum UID min_uid=0 ; Minimum GID min_gid=0
Web server setup
Next, you need to configure Apache. Open httpd.conf Add a listen line: Listen 2012
We prescribe virtual hosts (/ extra / httpd-vhosts.conf ):
<VirtualHost *:2012> Options +ExecCGI SSLEngine on SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL SSLCertificateFile "/home/recens/data/server.crt" SSLCertificateKeyFile "/home/recens/data/server.key" ServerName servername.com DocumentRoot "/usr/home/recens/data/public_html" suPHP_UserGroup root wheel CustomLog "/usr/home/recens/data/logs/recens-access.log" combined ErrorLog "/usr/home/recens/data/logs/recens-error.log" ServerAlias www.servername.com ServerAdmin admin@servername.com AddType application/x-httpd-php .php .php3 .php4 .php5 .phtml AddType application/x-httpd-php-source .phps </VirtualHost>
You must first generate server.crt and server.key for SSL support. This can be done with the help of a command like this: openssl req -new -newkey rsa:1024 -nodes -keyout server.crt -x509 -days 500 \ -subj /C=RU/ST=Msk/L=Msk/O=My\ Inc/OU=Sale/CN=bla/emailAddress=usr@dom.ru \ -out server.crt
Next you need to add information about the directive in /extra/httpd-userdir.conf or directly in httpd.conf : <Directory "/home/recens/data/public_html"> Options Indexes FollowSymLinks AllowOverride All Order allow,deny Allow from all </Directory>
Then do apachectl graceful
- Recens CP uses MySQL DBMS, which means you need to remember to import the database structure. It is located in the recens.sql file. You can import using phpMyAdmin . After importing, the user Admin will be created with the password password . Immediately, at the end of the installation , you must change the password!
IPFW
I use ipfw rules to collect primitive statistics. To install them, run as root:
ipfw add 10 count tcp from any to me dst-port 80 ipfw add 20 count tcp from me 80 to any
Cron
For everything to work, you need to add the following line to
/ etc / crontab :
*/5 * * * * root /usr/local/bin/php /home/paketik/data/public_html/recens/cron.php > /dev/null
Let's start editing the config.php config .
define("DEBUGMODE",1); define("DBHOST","localhost"); define("DBUSER","recens"); define("DBPASS","megapass"); define("DBNAME","recens"); define("TBLPREFIX","rec_");
- DEBUGMODE - 1/0 enable or disable error output to the browser.
- DBHOST is the host for the connection to the database.
- DBUSER - user to connect to the database.
- DBPASS - DB user password.
- DBNAME - base name
- TBLPREFIX - used prefix for tables.
Nothing more can not touch. Going to the address https: // yourdomain. com: 2012 / You should see the following:

After logon (Admin: password) we immediately go to the settings (
Other -> Settings ) and set a decent password. On the Dashboard tab, the "
Current system user " field should be "
root ".
')
A little about the possibilities
Dashboard Tab
- General info - General system information (system loading, HDD information, uptime, current user)
- Last logged into Recens - Last logged into the control panel. The first column is the identifier of whether the login attempt was successful. If the ip-address is highlighted in red, then it does not match the current one.
- Banned ips in IPFW - Banned ip firewalls are displayed here (I have sshit installed, which sends all ssh bruters there)
- Opened ports - Current open ports
Statistic tab
- HTTP traffic in - All incoming traffic on port 80 in the last hour
- HTTP traffic out - All outgoing traffic from port 80 in the last hour
- HDD usage - HDD usage diagram
- RAM usage - The currently used virtual memory diagram.
- CPU usage - CPU usage at the moment.
Tools tab -> Service manager
This is a web-based service management interface. Key features - reboot, stop, start the service.
Security tab
- Failed logins - You can see the entire history of failed logins with details for IP, User-Agent and Login.
- User manager - User changes. You can disable the user by setting him the status of Active "0"
- Firewall list rules - View IPFW rules
- Firewall add rule - IPFW editor
Other tab
- Settings - Change settings for the current user
- Languages - install language-packs
Screenshots:




In the next version (if there will be user support) it is planned:
- File manager
- Login by system accounts
- Any settings for services
- More statistics
PS Finish more and finish.
PPS Blog CMS, more successful did not find, if that - hint where to transfer.