04th Nov2014

ISPConfig/Dovecot Fix: message exceeds temporary size limit

by Gyro

A simple ISPConfig/Dovecot Fix: message exceeds temporary size limit.

I just setup a dedicated server as a webserver using ISPConfig as the control panel following pretty much this guide:
The Perfect Server -- Ubuntu 12.04 LTS (nginx, BIND, Dovecot, ISPConfig 3)

Everything went smoothly, until I setup and tested email addresses.

Thunderbird kept giving me this error popup when trying to send an email:

The size of the message you are trying to send exceeds a temporary size limit of the server. The message was not sent; try to reduce the message size or wait some time and try again. The server responded: (IP, Sender) first encounter..

So, I searched Google for that exact phrase as well as part of it, like "The size of the message you are trying to send exceeds a temporary size limit of the server" or "message exceeds a temporary size limit", and so on, then I finally found a small post that (accidentally?) contained the solution, a parameter that was missing in my config file!

It took quite a while to find the answer, so hopefully this post will help others to get the solution quicker :)

FIX: message exceeds temporary size limit

edit /etc/postfix/main.cf and add this (missing) line:

virtual_mailbox_limit = 0

Final step: restart dovecot:
$ service dovecot restart

Done, enjoy! :crazy:

Sources:
http://www.howtoforge.com/forums/showthread.php?t=1325
http://www.postfix.org/postconf.5.html

1334

23rd Jul2014

Ubuntu: Autostart Dropbox during Boot / System Startup

by Gyro

Today, I wanted to autostart dropbox during boot, so it is loaded during system startup and not only after I login.

To accomplish this, I needed to create a file and execute a few terminal commands.

1. Get startup script

Go to: dropboxwiki.com and click on the "Debian/Ubuntu" bar, copy the code.

2. Create a new file, paste the code into new file, and adjust it a bit

$ sudo nano /etc/init.d/dropbox

You need to provide the username(s) that use dropbox.
Edit the follwing line in the code, replace user1 user2 with the correct username(s):

DROPBOX_USERS="user1 user2"

Save the file, close editor, and make the file executable.
$ sudo chmod +x /etc/init.d/dropbox

3. Add the file to the autostart with lower priority

$ sudo update-rc.d -f dropbox remove
$ sudo update-rc.d dropbox defaults 98 02
This will load dropbox near the end of the system startup, found it in the ubuntuforums.

That should be all, enjoy :crazy:

3713

30th Jul2013

Cannot Change Screen Resolution for Ubuntu 12.04 Desktop

by Gyro

Today my Ubuntu decided to "forget" it got 2 monitors connected. Once I activated the 2nd monitor again, I could only choose a max screen resolution of 1024×768.

After some searching I found the solution on Ask Ubuntu :)

Open Terminal and type:
$ xrandr
it will show you the available screen resolutions for the connected monitors.

$ xrandr
Screen 0: minimum 320 x 200, current 2944 x 1080, maximum 8192 x 8192
HDMI-0 disconnected (normal left inverted right x axis y axis)
DVI-0 connected 1920×1080+1024+0 (normal left inverted right x axis y axis) 509mm x 286mm
1920×1080 60.0*+
1280×1024 60.0
1440×900 59.9
1280×800 59.8
1152×864 75.0
1024×768 70.1 60.0
800×600 60.3 56.2
640×480 66.7 60.0
720×400 70.1
VGA-0 connected 1024×768+0+312 (normal left inverted right x axis y axis) 0mm x 0mm
1024×768 60.0*
800×600 60.3 56.2
848×480 60.0
640×480 59.9

VGA-1 is the monitor that has a max screen resolution of 1024×769.

So, next command in terminal:
$ xrandr --addmode VGA-0 1920×1080

And check:
$ xrandr

$ xrandr
Screen 0: minimum 320 x 200, current 2944 x 1080, maximum 8192 x 8192
HDMI-0 disconnected (normal left inverted right x axis y axis)
DVI-0 connected 1920×1080+1024+0 (normal left inverted right x axis y axis) 509mm x 286mm
1920×1080 60.0*+
1280×1024 60.0
1440×900 59.9
1280×800 59.8
1152×864 75.0
1024×768 70.1 60.0
800×600 60.3 56.2
640×480 66.7 60.0
720×400 70.1
VGA-0 connected 1024×768+0+312 (normal left inverted right x axis y axis) 0mm x 0mm
1024×768 60.0*
800×600 60.3 56.2
848×480 60.0
640×480 59.9
1920×1080 60.0

Last step: Open Display settings and change the resolution for the monitor in question.

Done, enjoy ;)

Reference:

Screen resolution stuck at 1024×768

http://askubuntu.com/questions/37411/screen-resolution-stuck-at-1024×768

3938

21st Feb2013

Speed up your WordPress with CloudFlare!

by Gyro

My web hosting services provider ServerPilot has integrated CloudFlare into the cPanel!

CloudFlare is Content Deliver Network (CDN) with 22 data centers across the globe, and according to google there are only 9 web services in the world that have more traffic than CloudFlare. It is free, and it will make your website's load lightning fast from anywhere in world!

Even if your website is hosted with a slow hosting provider elsewhere, you can use CloudFlare for free!

If you give CloudFlare a try, make sure you also get the CloudFlare WordPress Plugin! WIth it, you can turn on the "Developer Mode" from your WordPress admin panel -- a must when updating your site, as changes won't show up immediately if the Developer Mode is turned off.

Enjoy! :enjoy:

1174

21st Feb2013

Restore large mysql databases with nginx 504 Gateway Timeout

by Gyro

I had to restore a 36MB sql database today and kept getting a "504 Gateway Time-out".

After playing around with the config files, adding fastcgi_read_timeout to the settings for php5-fpm, and fiddling with the php.ini, I realized that this can be accomplished with one single line using ssh:

Assuming that you have packed the .sql file into a zip file, and you are currently in that folder:
# gunzip < databasebackup.sql.gz | mysql -DDATABASENAME -uUSERNAME -pPASSWORD

DATABASENAME = name of the database
USERNAME = mysql username
PASSWORD = mysql password

I hope this helps when trying to restore large mysql databases with nginx 504 Gateway Timeout

2337

11th Feb2013

WHMCS: Round up product prices for secondary currencies

by Gyro

Today, I actually assisted my hosting provider in setting up secondary currencies in WHMCS, the billing and support system for/from cpanel! :)

They only wanted full numbers for the monthly breakdowns, so when they click "Update Prices" in the Currency Settings and a product would cost 1233.37 the price gets automatically rounded up to 1234.00.

Unfortunately, WHMCS doesn't offer this feature, so I suggested to setup a script on a secure location that they can trigger after they update the currency conversion rates and product prices. Below is the sql query that goes through all secondary currencies (1 = default currency) and rounds up the values, so that the setup fee and all monthly prices are full numbers.

The script itself would run a simple MySQL query:

UPDATE tblpricing SET
msetupfee = ceil(msetupfee),
qsetupfee = ceil(qsetupfee),
ssetupfee = ceil(ssetupfee),
asetupfee = ceil(asetupfee),
bsetupfee = ceil(bsetupfee),
tsetupfee = ceil(tsetupfee),
monthly = ceil(monthly),
quarterly = ceil(quarterly/3)*3,
semiannually = ceil(semiannually/6)*6,
annually = ceil(annually/12)*12,
biennially = ceil(biennially/24)*24,
triennially = ceil(triennially/36)*36
WHERE
currency != 1 AND
id = id

you could replace

currency != 1 AND

with
currency = 2 AND

or
currency IN(2,3,6) AND

etc

Enjoy :enjoy:

2275

04th Feb2013

Ubuntu update/upgrade fails with dpkg error message

by Gyro

Today, my Ubuntu was unable to install update.

I got this error message after trying to update Ubuntu:

dpkg: error: parsing file ‘/var/lib/dpkg/available' near line 15054 package ‘unity-common':
duplicate value for `Architecture' field
E: Sub-process /usr/bin/dpkg returned an error code (2)

After some research and trial'n'error, I came up with this solution:

1.Clear the content of the "available" file
# sudo nano /var/lib/dpkg/available
or
# sudo rm /var/lib/dpkg/available
# sudo touch /var/lib/dpkg/available

2. "Reset"
# sudo dpkg --configure -a
# sudo apt-get clean

3. Update/Upgrade again
# sudo apt-get update
# sudo apt-get upgrade

That should be all!

Step 2 may be unnecessary, but I have no way of testing it again… maybe someone with the same or a similar problem can try it without step 2 and let me know? ;)

1364

27th Aug2012

Keyboard Language Switcher Ubuntu Systray

by Gyro

I just installed another language to Ubuntu 12.04, and was a bit surprised not to find any icon in the systray (taskbar, top bar, notification area), also there was no shortcut I could find to make it change language.

In case you are trying to change the keyboard layout/language with a keyboard shortcut or setup the systray icon that looks like a keyboard to switch the language in the notificationa rea, then you've come to the right place :)

(more…)

7752

14th Aug2012

WordPress Automatic Update not working

by Gyro
I had an issue with WordPress automatic update not working on my localhost, instead it kept asking me to provide ftp login details?!

Even if I had a FTP server installed, which I don't, I prefer to use the Automatic Update Feature that comes with WordPress.

Of course there can be other similar issues leading to problems with updating wordpress, regardless of being installed locally on you PC, or running on a web server on the Internet. Most likely the reason for these problems will be permission errors, that prevent WordPress from saving any files during the update. So the solution will be to change the permissions for the folders in question.

Should you run a web server on your localhost (apache), then try this in the Terminal:

562127_Mojo_250x250_Browse100s

(more…)

1079

14th Aug2012

SoundBlaster 5.1vx activate all speaker channels Ubuntu 12.04

by Gyro
Today my sound card decided to stop playing sound on all 6 channels, and instead just played regular stereo (front left and right).

After some searching I found this simple fix to activate all speaker channels of a SoundBlaster 5.1vx on Ubuntu 12.04 Precise:

Open daemon.conf
# sudo nano /etc/pulse/daemon.conf

390160_Fluance SXHTB 125x125

(more…)

2861

26th Jul2012

Resize VirtualBox Disk Image – grow, expand, increase a .VDI disk image in 1 minute

by Gyro
Resize VirtualBox Disk Image -- the easy and the hard way.Today I actually used up the 20GB of virtual disk space I set for the Windows XP I use for specific Windows Software. Who would have thought that an old Windows XP license would be useful again, eh? :)

After performing a quick search on how to manipulate an existing VDI file, I found a bunch of lengthy guides, all pretty much saying the exact same thing… create a new VDI, load the old and new VDI disk images into a Virtual Machine as a master and slave drive, boot with a gParted or equivalent BootCD image, and then clone the old disk to the new one… or in short: do a lot of steps that take forever, but not what I want: Resize VirtualBox Disk Image.

virtualbox

After flipping through the 10th or so guide, I realized that pretty much all of them were written in 2008… very unusual as bloggers usually write about the same subject on a yearly basis. That in mind, I search a bit more and… BINGO! Since VirtualBox 4 is out, there is a simple command line tool to resize VDI images. Man, those extra 5 minutes of searching just saved me from a lot of hassle and a huge waste of time.
(more…)

379551

25th Jul2012

Android Installation on a HTC Touch Diamond 2 Topaz Windows Mobile

by Gyro
Today I put XDAndroid on a colleague's phone for the second time, after the memory card broke a couple of days ago.

This task is surprisingly easy, once you know what to do ;)

XDAndroid is a special version of Android, modified to work on older smart phones, like the HTC Touch Diamond 2 aka Topaz.

Up to 10% OFF Android Tablet PCs

Huge Savings Click Here!

(more…)

19684

25th Jul2012

Samsung SCX-3405W Network Printer & Scanner Installation/Configuration on Ubuntu 12.04

by Gyro
Today we got a new printer from Samsung, one reason being that the Installation CD boasted to support Linux. It's actually the first Samsung printer I ever used, so… the "Linux Installation" turned out to be a non-functional Java Applet, which looks like it is supposed to help setup the Printer to connect to the WiFi… needless to say -- it didn't work, at least not until after I had setup and configured the printer, at which point I didn't need to use it anymore.

I configured the wifi settings of the printer using the USB connection, a Windows PC, and the Windows portion of the Installation CD provided with the printer. After it was configured, I disconnected it from the USB, so there is only the power cable now.

Here is the quick and dirty guide on how to install the Samsung SCX-3405W Network Printer (and Scanner) on Ubuntu 12.04, which should also work for older Ubuntu releases, as well as other Debian based distributions.


(more…)

276358