Knowledge Base

Knowledge base of VeriTeknik

The other day we were working on a mail server of a customer’s that spammed insanely. Since the mail transfer agent it uses is exim, it’s necessary to check the mainlog files. Whilst doing that, we realized the server was getting a lot of incoming mails as forgery. So, it is possible to get the […]

I just added my whm/cpanel server to backup pool. I got the following error when trying to back up: Fatal error (bad version): stdin: is not a tty fileListReceive() failed Done: 0 files, 0 bytes Got fatal error during xfer (fileListReceive failed) Backup aborted by user signal Solution: I found that I had “mesg y” on […]

Here’s a simple bash script snippet I use for detecting the OS information on the current system. #!/bin/bash ### Getting OS Information if [ -f /etc/lsb-release ]; then . /etc/lsb-release DIST=$DISTRIB_ID DIST_VER=$DISTRIB_RELEASE else DIST=”Unknown” DIST_VER=”Unknown” fi if [ -f /etc/debian_version ]; then OS=”Debian” VER=$(cat /etc/debian_version) elif [ -f /etc/redhat-release ]; then OS=”Red Hat” VER=$(cat /etc/redhat-release) […]

Here’s something very basic yet poorly documented. That’s why it looks like almost everybody’s trying to hack their way into this module, the yum module for Python. First of all don’t forget that this module is only available if you’re using a Red Hat branch of distribution (fedora, centos etc.) For other distributions, such as […]

You are reading this article, most probably you faced trouble booting your Linux. Follow the steps below to fully chroot into your system as you booted regularly. Please note that we offer you to take a disk clone before doing anything in your boot configuration. To do so, you can use dd or dd_rescue to […]

If you want to show console output from a Serial device such as RS-232 interface, you need to make minor modifications in pfsense 2.0 distro. Switch to shell by pressing 8 from the pfsense console menu and edit the file /boot/loader.conf by typing: vi /boot/loader.conf Add the below lines to the file after pressin “i” […]

You wanna create a web based application, you have ideas but you have no idea about where to start. That is exactly where you should start using a MVC Framework. So what is a MVC Framework ? MVC is a programming pattern that comes with 3 components. M -> Model V -> View C -> […]

At the beginning of the year 2011, we decided to apply the IPv6 configuration to our data center (VeriTeknik) and requested our IPv6 block from RIPE. RIRs give out /32 blocks to LIRs at the first assignment. This article describes basic Cisco IPv6 configuration. The Preparation Steps Request your IPv6 Addresses from your RIR or […]

I have been looking a way to push e-mail since i got my iphone. Just found something for my test server and it works for me… I have a webserver running cPanel, Dovecot and suPHP. ( centOS 5.4, WHM 11.25 ) Steps: 1- You can download z-push from here. 2- Upload z-push to /usr/local/apache/htdocs 3- […]

I cannot get my flv files to load in Firefox but they work perfect in IE… My system is running apache. Finally, I found out that the problem was related with the Hotlink Protection implemented by some hosts through the .htaccess file and the fact that Flash does not send the referrer and Firefox does […]

Using LINUX as a server?, if so please read below Most of the Linux distros released as CD or DVD media for installing and if you install Linux with defualy options you get a nice user interface and a bunch of applications that you will never use in a server environment. Also default installation will […]

Running /tmp partition makes great performance enhancements as soon as you store temprorary information, please be aware that you mustn’t store valuable data as a reboot will flush all the data inside. /tmp & /var/tmp runs faster from RAM, to do so: vi /etc/fstab Switch to Insert mode by pressing I or INSERT button on […]

Vi is the one of the mostly used editor in Linux via terminal. In most cases where Linux is used as a server operating system, admins use the terminal, where GUI uses more system resources & network bandwidth. Since Vi is used from the terminal, the lack of GUI force the user to learn function […]

Updating RedHat & CentOS with Yum If you are using RedHat & its clones like CentOS or CloudLinux etc. you can use Yum or up2date to upgrade your current system. Please note that is you have a RedHat Enterprise Linux Subscription we offer you to use the command up2date, to upgrade your server with yum […]

You can use du command to see the folder size in LINUX including subfolders.: With du du -h # including subfolders (-h means human readable format in MB, GB or TB) If you want to exclude subfolders, type: du -h –max-depth=1   If you want to know a specific folders size (easy to remember) type: […]

In default LINUX installation IPv6 is enabled. IPv6 might use system resources or for what ever reason you have Run this command as root: echo “alias net-pf-10 off” >> /etc/modprobe.conf echo “alias ipv6 off” >> /etc/modprobe.conf You need to restart your server after this command.

LINUX Version Info To learn the architecture and kernel version info use the shell command below: less /etc/redhat-release The output will be like CentOS release 5.6 (Final) To learn the architecture & kernel version: uname -a you can use the command above, the last numbers marked as red below is your architecture: Linux xxx.veriportal.com 2.6.18-164.9.1.el5 […]

NTP (Network Time Protocol) could be used to set time synced with ntp clocks, to do this use the shell command below: Setting time with NTP: yum install ntp -y \cp -f /usr/share/zoneinfo/Europe/Istanbul /etc/localtime ntpdate -v -b in.pool.ntp.org And set the hardware clock with: hwclock -w

You can make a search inside files within a a directory using the command “find“, to do that: with the find command cd /to_folder find . -iname ‘*conf’ | xargs grep ‘string’ -sl -iname ‘*conf’ states that the seach will only check the files ending with *conf, using -iname ‘*’ will search inside all the […]

If you own your DNS servers, you should probably want to close recursive queries being gathered from your servers. In named.conf edit the options directive and add: options { allow-transfer {Secondary Server IP; }; allow-recursion { 127.0.0.1; A.B.C/24; }; }; In secondary server: add to options: allow-transfer { none; }; allow-recursion { 127.0.0.1; A.B.C/24; };

I find Joomla non-developer friendly for the most of the time; documentation is poor and not having any continuity. I searched the net for displaying errors to the screen in Joomla 1.5 and up and here is the code: JError::raiseWarning(‘101’, “message to be displayed”); This bunch of code is especially useful if you are developing […]

If it appears to be all (***) instead of your mail hostname and if you get, “550 Sorry, your HELO/EHLO greeting must resolve (#5.7.1)” error when sending mail to your mail server from outside, run the following command in your CISCO firewall: no fixup protocol smtp 25 and save with the “wr mem” command

The standart linux distrubition calls that the ephemeral port range be between 1024 and 4999. We we all know that some of these ports are used for other more importand applications than FTP. So security is an issue because leaving those original ports open leads to major security holes. Rather than openning ports that need […]