Change php.ini for adjust max upload file size

File too large

That simple message when marketing team want to upload new support ticket that include attachment with size 4 MB.

Yes, that my mistake for not adjust default max upload file size.

The solution is simple :

Edit php.ini file

I use ubuntu and because I more familiar with freebsd I use phpinfo() as my friend to find out where the file is.

According to phpinfo() the php.ini file located in :

/etc/php5/cgi/php.ini

Open that file with nano editor :

# nano /etc/php5/cgi/php.ini

change “upload_max_filesize” to other value. I use 8M.

Save the file.

Continue reading

Install pureftp with unixauthentification on ubuntu

I used to use winscp to upload file to vps server. It’s easy and I just need to keep dedicated user.

Due to request for ftp support I decide to install ftp server called pure-ftp on ubuntu jaunty.

Install pure-ftp

# apt-get install pure-ftpd

Reading package lists… Done
Building dependency tree
Reading state information… Done
The following extra packages will be installed:
libcap1 pure-ftpd-common
Suggested packages:
netkit-inetd openbsd-inetd xinetd
The following NEW packages will be installed:
libcap1 pure-ftpd pure-ftpd-common
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 355kB of archives.
After this operation, 1040kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://archive.ubuntu.com jaunty/main libcap1 1:1.10-14build1 [9780B]
Get:2 http://archive.ubuntu.com jaunty/universe pure-ftpd-common 1.0.21-11.4ubuntu1 [176kB]
Get:3 http://archive.ubuntu.com jaunty/universe pure-ftpd 1.0.21-11.4ubuntu1 [169kB]
Fetched 355kB in 1s (278kB/s)
Preconfiguring packages …
Selecting previously deselected package libcap1.
(Reading database … 20798 files and directories currently installed.)
Unpacking libcap1 (from …/libcap1_1%3a1.10-14build1_amd64.deb) …
Selecting previously deselected package pure-ftpd-common.
Unpacking pure-ftpd-common (from …/pure-ftpd-common_1.0.21-11.4ubuntu1_all.deb) …
Selecting previously deselected package pure-ftpd.
Unpacking pure-ftpd (from …/pure-ftpd_1.0.21-11.4ubuntu1_amd64.deb) …
Setting up libcap1 (1:1.10-14build1) …

Setting up pure-ftpd-common (1.0.21-11.4ubuntu1) …

Setting up pure-ftpd (1.0.21-11.4ubuntu1) …
Starting ftp server: Running: /usr/sbin/pure-ftpd -l pam -E -O clf:/var/log/pure-ftpd/transfer.log -u 1000 -B

Processing triggers for libc6 …
ldconfig deferred processing now taking place
You have new mail in /var/mail/root
#

Enable unixauthentification

# nano /etc/pure-ftpd/conf/UnixAuthentication

change  from no to yes and save the file.

Run the service

# /etc/init.d/pure-ftpd start

Starting ftp server: Running: /usr/sbin/pure-ftpd -l unix -l pam -E -O clf:/var/log/pure-ftpd/transfer.log -u 1000 -B
#

Great, I can delegate website update process :-)

freebsd unzip ports

I just use gunzip as tool for unzip an .zip file at ubuntu 10.04 when I try same utility at freebsd.

Now I want to try something new with utility called unzip.

Try to call it ( it might be installed)

# unzip
unzip: Command not found.

Not found, try to find installation file.

# whereis unzip

unzip: /usr/ports/archivers/unzip
# cd  /usr/ports/archivers/unzip && make install

Continue reading

Warning: No configuration file found!

Try to install gammu with newest ubuntu version (lucid). smsdrc edited and lauch gammu–identify

# gammu –identify

Warning: No configuration file found!
Warning: No configuration read, using builtin defaults!
No response in specified timeout. Probably phone not connected.

I check the cable and it looks fine.

Check configuration file and yes, still at /etc/gammu-smsdrc

Retry by give -c option :

# gammu -c /etc/gammu-smsdrc –identify

Device               : /dev/ttyUSB0
Manufacturer         : Wavecom
Model                : unknown (MULTIBAND  900E  1800)
Firmware             : 652a09gg.Q2406A 1489876 060706 17:19
IMEI                 : 35162100049xxxx
SIM IMSI             : 51008004196xxxx

I see.

symbolic link will help :

ln -s /etc/gammu-smsdrc /etc/gammurc

error fix.

Upgrade Clamav for older FreeBSD box : This version of the ClamAV engine is outdated

One of my FreeBSD box that use version 6.3 stop working. Futher investigation lead me to old clamav version that forced to upgrade by clamav.net .

This version of the ClamAV engine is outdated

I think about upgrade the box to newer version like 7.3 or 8.0 release but final choice I pick is :

Let it as is :-)

Just focus on clamav because everything running well and I don’t want to risk anything that might happen ( ports conflict, new config etc)

My method :

1. Update ports to latest version.

2. Check clamav version

# portversion -v | grep clamav

clamav-0.94.2               <  needs updating (port has 0.96_1)

3. Downgrade ports file for clamav using portdowngrade ( I choose version 0.95.3)

4. Reinstall Clamav.

# portversion -v | grep clamav

clamav-0.95.3               <  needs updating (port has 0.96_1)

5. Restart clamav

# /usr/local/etc/rc.d/clamav-clamd restart

# /usr/local/etc/rc.d/clamav-freshclam restart

Email server back to business.

P.S : in case you want to skip portdowngrade section you can use my clamav ports.

clamav.tar