Recent Updates Page 2 Toggle Comment Threads | Keyboard Shortcuts

  • Jay Versluis 10:01 am on April 13, 2015 Permalink | Reply  
    Categories: Announcements, Linux ( 7 )

    LAMP Stack for Humans – now available on Amazon 

    Lampstack-SoftcoverMy new book LAMP Stack for Humans is now available on Amazon. It this 284 page guide I’ll walk you through the process of turning an old laptop into an always-on server. You can use it to run web applications in the comfort of your own home or office – no “cloud” required.

    Together we will configure the entire server: you will learn how to install CentOS, Apache, PHP and MySQL (or MariaDB) and WordPress. I will show you how you can reach your server from other computers on the network and how to create regular backups.

    Perfect for the Linux newbie and those who want to get started with web applications without spending money “in the cloud” (in my opinion THE WORST expression for describing remote computers).

    If you’re an avid reader of this site and have always wished that some instructions would be presented in a more cohesive form rather than in snippets, then LAMP Stack for Humans is perfect for you.

     

    Grab your free sample today, or read the entire book for free via Kindle Unlimited!

     

     
  • Jay Versluis 4:27 pm on April 9, 2015 Permalink | Reply
    Tags: ,   

    Categories: Linux ( 68 )

    How to edit your network connection settings from the command line in CentOS 7 

    CentOS 7 has a very funky text-based user interface that allows editing several important network connection settings. It’s called nmtui.

    Type the command without any parameters to get started:

    nmtui

    Now use this handy interface:

    Screen Shot 2015-04-09 at 16.22.13

    Screen Shot 2015-04-09 at 16.22.59

    Screen Shot 2015-04-09 at 16.22.33

    Your system may require a full restart for all settings to take affect.

     
  • Jay Versluis 4:15 pm on April 9, 2015 Permalink | Reply
    Tags: , ProFTP   

    Categories: Plesk ( 65 )

    How to allow resuming FTP uploads in Plesk and ProFTP 

    Plesk-LogoProFTP has a handy feature that lets uploads resume if they were interrupted, much like Safari downloads. This feature has to be enabled both on the server and the client.

    By default however, resuming uploads are disabled for security reasons – a wise precaution if anonymous uploads are allowed to a server. Here’s how to enabled it.

    Plesk uses ProFTP, and all we have to do is add a couple of lines to the /etc/proftpd.conf file. Anywhere will do, as long as it’s outside the “global” tags:

    # allow resuming file uploads
    AllowStoreRestart on
    AllowOverwrite on
    

    ProFTP is part of the xinetd system service, and for the change to take effect we’ll have to restart this:

    service xinetd restart
    

    To make use of this feature, an FTP client needs to support this feature too: in FileZilla it’s under Settings – Transfers – File Exists Action:

    Screen Shot 2015-04-09 at 12.40.26

     
  • Jay Versluis 4:39 pm on April 6, 2015 Permalink | Reply
    Tags:   

    Categories: Plesk ( 65 )

    How to move the vhosts directory in Plesk 

    Plesk-LogoThe default directory for all web files in Plesk on Linux is /var/www/vhosts. Usually this works well, but if you’d like to use another partition instead, you’ll be pleased to hear that you can!

    Parallels (or Odin as we call them now) have written a handy script which moves the content and patches the relevant configuration file and copies all content at the same time. The script is called transvhosts and you can download it here:

    Download it using wget and make the file executable:

    wget http://kb.sp.parallels.com/Attachments/kcs-12467/transvhosts.pl
    chmod +x transvhosts.pl
    

    It’s a PERL script, which means it needs prefixed with ‘perl’ to be called. Say you want to move your vhosts directory to /home/vhosts, you’d call it like this:

    perl transvhosts.pl --dest-dir /home/vhosts --correct-scripts
    
    Moving files to new directory...
    Correct psa configuration file...
    Correct passwd file...
    Correct server configuration files...
    Clean up symlinks...
    /etc/httpd/conf/plesk.conf.d/vhosts
    Correct php-fpm pools configuration...
    Moving files to new directory...
    Correct psa configuration file...
    Correct passwd file...
    Correct server configuration files...
    Clean up symlinks...
    /etc/httpd/conf/plesk.conf.d/vhosts
    Correct database...
    Update hosting settings...
    done
    Update subdomains settings...
    done
    Update system users settings...
    done
    The service node 'local' was successfully updated.
    Correct user scripts...
    

    This may take a moment or two depending on the amount of content you have in the current directory. The script will patch Plesk’s configuration file and restart the panel. There’s minimal downtime in involved in this process.

     
  • Jay Versluis 3:55 pm on April 3, 2015 Permalink | Reply  
    Categories: Windows ( 14 )

    How to show file extensions in Windows 

    Windows IconThere are several ways to make the Windows Explorer show full file extensions.

    The most consistent method I like to use is the following:

    Windows 7 and 8

    1. click Start to find a Search Box
    2. type Folder Options and select it
    3. click the View Tab
    4. find the option “hide extensions for known file types”
    5. untick it and hit apply

    Screen Shot 2015-04-03 at 15.38.10

    Windows 10

    1. click Start to find a Search Box
    2. type File Explorer Options and select it
    3. select the View Tab
    4. find the option “hide extensions for known file types”
    5. untick it and hit apply

    Screen Shot 2015-04-03 at 15.48.29

     
  • Jay Versluis 11:00 am on March 31, 2015 Permalink | Reply
    Tags: Editor   

    Categories: WordPress ( 111 )

    How to disable the WordPress Theme and Plugin Editor 

    AppIcon76x76@2xOne of my readers had a mysterious problem: the WordPress Editor was not showing up under Appearance or Plugins. It’s a handy tool for quick edits to any plugin or theme file, and I’ve relied on it more times than I can count.

    Having it enabled is a double-edged sword of course, because with great power comes great responsibility too: make a change to a plugin file and accidentally remove a semicolon from the end of a line, and your WordPress site will go down – and the best minds will have a hard time tracking the problem down.

    There is a way to remove the editor functionality completely from WordPress to save tinkerers from themselves: add the following line to the wp-config.php file:

    define('DISALLOW_FILE_EDIT', true);
    

    This will remove the Editor from both Appearance and Plugins. The change will be in effect as soon as you save the file and refresh the admin interface.

    Screen Shot 2015-03-31 at 10.51.27

    Screen Shot 2015-03-31 at 10.36.58

    To bring the editor back, simply remove the entire line from wp-config.php, or set the value “true” to “false”.

    Many thanks to Dr. Markus Drabe for bringing this puzzle to my attention!

     
  • Jay Versluis 3:23 pm on March 27, 2015 Permalink | Reply
    Tags: Finder   

    Categories: Mac OS X ( 17 )

    How to show hidden files in the Mac Finder 

    Hidden files start with a . on UNIX like systems and OS X is one of them. While we can show hidden files in a Ternimal session by using something like ls -a, it’s not so easy to convince the Finder to show such files.

    If ever you need to see them, execute the following from the command line:

    defaults write com.apple.finder AppleShowAllFiles YES
    

    Now relaunch Finder ALT-right-clicking the Finder icon in the dock. Choose Relaunch.

    Screen Shot 2015-03-27 at 15.17.42

    Next time you open a Finder window – either on its own or via an app – you’ll see all kinds of files you didn’t even know existed. They all begin with a dot and are slightly lighter in colour. Others are system folders, such as Library.

    So many new files can make your file navigation a little cluttered – which is why it’s good to know how to switch this feature off again. Same command as above, but this time we’ll say no:

    defaults write com.apple.finder AppleShowAllFiles NO
    

    Thanks to Ian Lunn for this tip:

     
  • Jay Versluis 9:29 am on March 27, 2015 Permalink | Reply
    Tags: ,   

    Categories: Plesk ( 65 )

    Parallels Cloud Services changes into Odin 

    Odin Logo

    Parallels have announced this week that they’ve changed their name to brand cloud services from Parallels to Odin. This blog post has more details:

    While I dislike change for the sake of change, I believe that it makes a lot of sense in this case. I have been working with Parallels products since 2008, and when I started out I always thought there was a dissociation between the consumer products, such as Parallels Access and Parallels Desktop, and the professional products, such as Plesk.

    The Odin branding will be used for the latter line of products, while the Parallels branding will continue to be used for Parallels Desktop & Co. Parallels Plesk will simply be known as “Plesk”.

    The company itself will remain a single unit for now, simply operating under two brands.

    In case you’re wondering what will become of all those Parallels Summits, they will be renamed to Odin Summits. The first one with this branding will be in May: http://www.odin.com/summit/2015/

    Long live Odin!

     
  • Jay Versluis 12:36 am on March 25, 2015 Permalink | Reply  
    Categories: Linux ( 68 )

    How to find the UUID of a disk drive in Linux 

    There are two ways I know of which will print the UUID of all disk drives attached to the current system:

    blkid
    
    /dev/sr0: UUID="2014-12-02-19-30-23-00" LABEL="CDROM" TYPE="iso9660" 
    /dev/sda1: UUID="ae55a647-3c57-4ab5-9651-1389703fe6fe" TYPE="ext4" 
    /dev/sda2: UUID="bMtCfO-zpDU-7U1t-DcHg-Fe9p-Cy1K-Se0e1I" TYPE="LVM2_member" 
    /dev/sdb1: UUID="0982ce66-537a-497b-baaf-99136594f3e8" TYPE="ext4" 
    /dev/mapper/VolGroup-lv_swap: UUID="8f0652a8-d79b-453f-aa2d-0ff0b5d0ae7b" TYPE="swap" 
    /dev/mapper/VolGroup-lv_root: UUID="5afc1b25-e6cd-45b2-ad20-69f0fed323b9" TYPE="ext4" 
    /dev/mapper/VolGroup-lv_home: UUID="94e15e98-1cff-49a9-b76a-a8f3a948e2ea" TYPE="ext4" 
    

    or

    ls -la /dev/disk/by-uuid
    
    total 0
    drwxr-xr-x. 2 root root 160 Mar 25 00:24 .
    drwxr-xr-x. 5 root root 100 Mar 25 00:24 ..
    lrwxrwxrwx. 1 root root  10 Mar 25 00:24 0982ce66-537a-497b-baaf-99136594f3e8 -> ../../sdb1
    lrwxrwxrwx. 1 root root   9 Mar 25 00:24 2014-12-02-19-30-23-00 -> ../../sr0
    lrwxrwxrwx. 1 root root  10 Mar 25 00:24 5afc1b25-e6cd-45b2-ad20-69f0fed323b9 -> ../../dm-1
    lrwxrwxrwx. 1 root root  10 Mar 25 00:24 8f0652a8-d79b-453f-aa2d-0ff0b5d0ae7b -> ../../dm-0
    lrwxrwxrwx. 1 root root  10 Mar 25 00:24 94e15e98-1cff-49a9-b76a-a8f3a948e2ea -> ../../dm-2
    lrwxrwxrwx. 1 root root  10 Mar 25 00:24 ae55a647-3c57-4ab5-9651-1389703fe6fe -> ../../sda1
    

    The UUID is required to permanently mount specific disk drives in /etc/fstab.

     
  • Jay Versluis 9:57 am on March 23, 2015 Permalink | Reply
    Tags: , ,   

    Categories: Mac OS X ( 17 )

    How to disable the ultra annoying Startup Sound on Mac OS X 

    Yosemite

    I passionately *H*A*T*E* the startup chime that my Mac makes when I switch it on. At least on my MacBook, if the volume is turned down before I shutdown, the system restarts silently. I guess it’s somehow linked to the internal speakers.

    Sadly on my Mac Mini this approach doesn’t work: due to the lack of “real” internal speakers , the Mini always wakes up with that horrible eighties K-DONNNNNNNNG noise, waking up my wife and large parts of the neighbourhood.

    But there’s good news: thanks to the nvram command we can set a firmware value to suppress this sound. Here’s how:

    sudo nvram SystemAudioVolume=%80
    

    This will write a value of 128 (or 80 in hex) to the BIOS. Make sure to shutdown your system and then power back on to “hear” the effect on a Mac Mini: simply restarting it will not suppress the sound, but a full shutdown and restart will do the trick from now on. Result!

    As much as I dislike the sound, it is there for a reason: it signals the successful completion of a quick self test. I appreciate this – so I may not want to switch K-DONNNNNNNNG off forever.

    It’s easy to remove that value again from the BIOS, using the -d parameter of the same command:

    sudo nvram -d SystemAudioVolume
    

    There. Now the horror chime is enabled again, ready to annoy more neighbours at 3am.

    Kudos to the following sources:

     
c
compose new post
j
next post/next comment
k
previous post/previous comment
r
reply
e
edit
o
show/hide comments
t
go to top
l
go to login
h
show/hide help
shift + esc
cancel