The Blog

Linux

How to mount Amazon’s S3

Posted on

S3FS is FUSE (File System in User Space) based solution to mount an Amazon S3 buckets, We can use system commands with this drive just like as another Hard Disk in system. On s3fs mounted files systems we can simply use cp, mv and ls the basic Unix commands similar to run on locally attached disks.

If you like to access S3 buckets without mounting on system, use s3cmd command line utility to manage s3 buckets. s3cmd is also provides faster speed for data upload and download rather than s3fs. To work with s3cmd use next articles to install s3cmd in Linux systems and Windows systems.
Read More

Posted in Linux Leave a comment

Installing dbase.so for PHP5 on Ubuntu 14.04

Posted on


sudo apt-get install php-pear
sudo apt-get install php5-dev

sudo pecl install dbase

sudo vi etc/php5/mods-available/dbase.ini < extension=dbase.so
sudo php5enmod dbase

sudo service apache2 restart

That should do it. I would do that on a temp Ubuntu and just copy the dbase.so to the prod, so you do not install all that dev stuff in your prod env.

Posted in Linux, PHP 71 Comments

Archive files and folders in Linux

Posted on

ASSERT: No files have newline characters in them. Spaces, however, are AOK.

# TEST FIRST: CREATION OF FOLDERS
find . -type f -iname \*.mov -printf ‘%h\n’ | sort | uniq | xargs -n 1 -d ‘\n’ -I ‘{}’ echo mkdir -vp “/TARGET_FOLDER_ROOT/{}”

# EXECUTE CREATION OF EMPTY TARGET FOLDERS
find . -type f -iname \*.mov -printf ‘%h\n’ | sort | uniq | xargs -n 1 -d ‘\n’ -I ‘{}’ mkdir -vp “/TARGET_FOLDER_ROOT/{}”

# TEST FIRST: REVIEW FILES TO BE MOVED
find . -type f -iname \*.mov -exec echo mv {} /TARGET_FOLDER_ROOT/{} \;

# EXECUTE MOVE FILES
find . -type f -iname \*.mov -exec mv {} /TARGET_FOLDER_ROOT/{} \;

Posted in Linux Leave a comment

Installing wkhtmltopdf on Ubuntu Server 12.04 or 14.04

Posted on

14.04

Steps:

  1. At first install xvfb server:
    sudo apt-get install xvfb
  2. Get needed version of wkhtmltopdf from http://wkhtmltopdf.org/downloads.html.For Ubuntu 14.04 64-bit:
    wget http://download.gna.org/wkhtmltopdf/0.12/0.12.2.1/wkhtmltox-0.12.2.1_linux-trusty-amd64.deb
  3. Install wkhtmltopdf:
    sudo dpkg -i wkhtmltox-0.12.2.1_linux-trusty-amd64.deb

    Install dependency (if needed):

    sudo apt-get -f install
Posted in Linux Tagged , ,
« Previous PageNext Page »