All posts by l4urenz

Colourfull CLI

The Bashrc file controls the options in your terminal.
In order to open that file enter the following command:

  • sudo nano ~/.bashrc

Look for the line and uncomment it:

#force_color_prompt=yes

to be:

  • force_color_prompt=yes

save then execute source ~/.bashrc

When you reconnect to your terminal, you should see some fancy colours.

Diskcleanup on 2008 R2

Have you ever found yourself missing the “disk cleanup”  tool to clean a server or of its much needed C:\ space. Wait no longer..

First stop could be, to install the Windows Desktop Experience feature, but this requires a reboot and will install also other application, you might not want..

So how about, if you could just copy 2 files and run the application.

 

Operating System Architecture File Location
Windows Server 2008 R2 64-bit C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr_31bf3856ad364e35_6.1.7600.16385_none_c9392808773cd7da\cleanmgr.exe
Windows Server 2008 R2 64-bit C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.1.7600.16385_en-us_b9cb6194b257cc63\cleanmgr.exe.mui
Windows Server 2008 64-bit C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.0.6001.18000_en-us_b9f50b71510436f2\cleanmgr.exe.mui
Windows Server 2008 64-bit C:\Windows\winsxs\amd64_microsoft-windows-cleanmgr_31bf3856ad364e35_6.0.6001.18000_none_c962d1e515e94269\cleanmgr.exe.mui
Windows Server 2008 32-bit C:\Windows\winsxs\x86_microsoft-windows-cleanmgr.resources_31bf3856ad364e35_6.0.6001.18000_en-us_5dd66fed98a6c5bc\cleanmgr.exe.mui
Windows Server 2008 32-bit C:\Windows\winsxs\x86_microsoft-windows-cleanmgr_31bf3856ad364e35_6.0.6001.18000_none_6d4436615d8bd133\cleanmgr.exe

Once you’ve located the files move them to the following locations:

  1. Cleanmgr.exe should go in %systemroot%\System32.
  2. Cleanmgr.exe.mui should go in %systemroot%\System32\en-US.

You can now launch the Disk cleanup tool by running Cleanmgr.exe from the command prompt.

 

Sources:
Windows KB page

Installing MemCached

Memcached is a high performance in-memory caching system that can be used to speed up applications and websites that use databases. Memcached does not write to disk, instead store its content in system memory which makes it faster.

Majority of the content management systems in used today have tools to take advantage of Memcached. If configured correctly, you may be able to see huge improvements to your websites and applications.

This brief tutorial shows you how to install Memcached on Ubuntu 17.04 / 17.10 servers

Continue reading Installing MemCached

Updating Ubuntu servers

One of the most effective ways to protect your servers is by updating them regularly. These updates and patches are released to fix security vulnerabilities, enhance performance and resolve issues.

The process of updating Ubuntu is fairly simple. All one needs is administrative access to the server terminal usually via SSH or other means.

Advanced Packaging Tool (APT) is a powerful command line tool which works with Ubuntu. It’s the default package management and installation tool for Ubuntu and other distributions.

Checking For Updates On Ubuntu Servers

To check for updated software that are available for Ubuntu server, run the commands below.

sudo apt-get update && apt-get -s upgrade

The command above will is all or any upgradable packages to choose from and give you the option to upgrade a single package or all the packages on the system.

Updating Ubuntu Packages

A single command s used to update all Ubuntu install packages. That command is shown below:

sudo apt-get update

You can also run the commands below to update as well as upgrade Ubuntu packages at the same time.

sudo apt-get update && sudo apt-get dist-upgrade

When you run the above commands, you’ll be prompted to confirm the update. You can then type Y for yes and press Enter to continue with the updates. Depending on the size of the update and your Internet connection speed, it may take few minutes to an hour.

After all the packages are downloaded and installed,  you can continue working and knowing that you server is updated and protected.