Linux.com

Home Linux Community Community Blogs

Community Blogs



Schedule Your Jobs in Linux With CRON

Most of the Linux users are aware of how commands are run, processes are manipulated and scripts are executed in terminal. But, if you are a Linux system administrator, you might want them to start and execute automatically in the background. As an example, you might consider running a backup job every day, at a specific time, automatically. Or you might consider an example of collecting inventory data of the systems deployed across your network, by running a script automatically on monthly basis. But, how to schedule these jobs and execute them automatically in Linux?

    There is an utility in Linux known as CRON with which you can start your jobs automatically at a desired time and schedule them to get executed periodically.

    Cron utility consists of two parts: The cron daemon and the cron configuration files. Cron daemon is just like any service that is started automatically whenever your system boots. Cron configuration files hold the information of what to do and when to do. The main job of cron daemon is to inspect the configuration regularly (every minute to be more precise) and check if there is any job to be completed.

    In the /etc directory, you will find some sub-directories namely cron.hourly, cron.daily, cron.weekly and cron.monthly. You can put your scripts in these directories, and as their names suggest, they will be automatically executed after certain period of time. For example, if you wish to run a job or service regularly after every week, simple put the script in /etc/cron.weekly directory.

 

Read more at YourOwnLinux.

 

 

5 Best Free Erlang Books

The focus of this article is to select the finest Erlang books which are available to read for free. Some of the books featured here are released under an open source license. All of the texts have a lot to offer for a budding Erlang programmer.

<A HREF="http://www.linuxlinks.com/article/20140510054337787/FreeErlangBooks.html">Read more</A>

 

19 cool things to do after installing Kubuntu 14.04 Trusty Tahr

Kubuntu 14.04 Ubuntu 14.04 LTS has been recently released and Kubuntu 14.04 followed up swiftly. Kubuntu is been my primary distro for many years now. It brings together the wonderful KDE desktop along with the app laden Ubuntu. So if you have just done a fresh install of Kubuntu then you can tweak few things and install some apps to make sure everything from multimedia to office apps and browser functionality works in the best possible...
Read more... Comment (0)
 

Does Tor Browser Just Open a Text Editor? Here's a Simple Fix

If you use Ubuntu, then you're probably familiar with the nuisance of running Tor Browser. Yes, I know, when you click "Run-Tor-Browser", it just opens a gedit text window. Let's change that with one simple step.

 

Open your terminal and type:

gsettings set org.gnome.nautilus.preferences executable-text-activation ask

 

 

How To Build a Cloud (cluster) Hosting Without Investing a Lot of Money

Three years ago, I had an interesting problem. It was necessary to assemble a platform to combine multiple racks of servers into a single entity for the dynamic allocation of resources between sites, written for the LAMP platform.

However, the budgets were very less so expensive solutions such as Cisco Content Switch or disk shelves with fiber optics were not affordable.

And, besides, of course, in case if one server is down – this should not affect the operation of the platform was my main concern.

In my school time, I read somewhere that “Necessity is the mother of invention”, which is fairly true.

First of all you need to share a platform into subtasks. You have to do something for the synchronization of data as a shared drive is available. In addition, it is necessary to balance the traffic and have at it some statistics. Finally, the automation of providing the necessary resources – is also quite a serious problem.

Let’s start from the beginning…

I had a choice on what to organize a platform. OpenVZ or XEN ? Each has its pluses and minuses. OpenVZ has a lower overhead, work with files and does not block devices, but cannot run anything other than Linux’ovh distributions. XEN allows you to run on Windows, but more difficult work. I’ve been using OpenVZ, as this is more suited for the task, but you can choose the one you like, there is no restriction on choice.

Then I shared the server space for the VDS, one for each core. Servers were different, and therefore I had a set from 2 to 16 and virtual ok on each server. In the “average house” turned out about 150 virtual ok on the counter.

How to synchronize the data?

The next item – this is the early establishment of VDS on demand + protection against breakage of any server. The solution was simple and beautiful.

Each VDS creates the initial image as a file on the LVM partition. This image “spreads” on all servers in the platform. As a result, we have a backup of all the projects on each server (paranoid cry of emotion), and the creation of a new VDS «on demand” has been simplified to a snapshot image and it start the VDS literally in few seconds.

Database and API

If the integrity of the files were all simple, here’s a sync base things were worse. From the beginning I tried a classic example – master-slave, and collided with a classic problem: slave lag behind master.

The next step was to Mysql-Proxy. As a sysadmin, this was very easy to set and forget, but the configuration should be updated while adding / removing new VDS. But developers have had their own opinion. In particular, the fact is that, it is easier to write a PHP class for synchronization of INSERT / UPDATE / DELETE queries than to learn Lua, without which the Mysql-Proxy is useless.

Their work produced a so-called API, which was able to find neighbors of a broadcast sync up to date and to inform the neighbors of any changes to the database.

But still worth exploring Lua and make native mode, where all requests are synchronized with their neighbors.

FreeBSD

Balancer – it can be said that it is a key aspect of the platform. If they fall to balance server, all work will have no meaning.

That is why I used the CARP to create fault-tolerant balancer, choosing FreeBSD as the OS and Nginx as a balancer.

Yes, NLB has been replaced by two weak machines with FreeBSD (marketers in a rage).

And most importantly – how it works

When starting up the platform for each site runs on a single copy and monitor to balanesere watched to ensure that the primary copy has always worked.

In addition, the balancer was installed to analyze statistics Awstats, which provided all the logs in a convenient format, and most importantly – there was a script, polling each VDS via SNMP for its load.

As we remember, I devoted each VDS on one core, so Load Average in a 1 – this is a normal load for the VDS. If LA became 2 or above – the script that creates a copy of the VDS on a random server and put this in its upstream nginx’a. And when the load on extra VDS fell less than 1 -, respectively, all removed.

Summarize

If you take the rack with servers and switches supporting the CARP protocol, to create a ESDS cloud hosting Server, will need to:

  • Explore Lua and adjust transparent synchronization across Mysql-Proxy
  • Screw the billing account for additional copies of the VDS and traffic
  • Write a web interface for managing VDS
  • The filling racks with enough amount of four zeros. Compared with the decisions of the brands, where the price of one stand is the sum of six zeros, counts worth.
 

An Insight On Dedicated Server Terminology

At times, technical jargon can become overcomplicated and it further complicates simple matters as well. While investigating the web hosting servers, you will often come across titles like ‘The beginner’s guide’ or ‘simple steps’ that comprises of words like hypertext, applet and many other unexplained acronyms.

As compared to the other web hosting platforms, dedicated hosting is comparatively a complicated hosting solution and it takes some time to get accustomed to it. It is important to understand the benefits of a dedicated server and know the reasons why you should opt for this hosting solution. Once you have this basic understanding, you must move forward and gain knowledge of some of the crucial words and phrases that are going to be useful for gaining an insight on the functioning of a dedicated server.

The aim of this article is not to burden the users with explanations but just to educated them on the basic terminology of dedicated servers that they must be aware of. Here is a brief explanation of the important terms:

Initially, let’s have a look at the concept – dedicated server. Basically, this is your personal server where there is no need for you to share the resources as the server is completely dedicated to you. This is a flexible hosting solution that enables you to decide on the factors like operating systems, hardware and the other resources on the server. Dedicated servers usually provide with high security and better performance as compared to the other hosting platforms. Although a dedicated server has a higher price tag, it is a complete value for money for the resource intensive websites.

DNSBL (DNS blacklist); this is something you don’t want to see. You might come across this term when your server is blacklisted. This term is used for the networks that distribute spam or any type of harmful services. Usually, it is a list of blacklisted IP addresses that you wouldn’t like to deal with for some or the other reason.

While the offerings of many web hosting companies comprise of unmanaged dedicated servers, another term that you might come across is – managed servers. As dedicated servers are more personal and private, there is no interference caused by others. This means that you can configure the server as per your preference. By selecting a managed dedicated server, you will be provided with round the clock support by the web hosting company and they will maintain the server and ensure the smooth functioning of the server.

The name server is the server that translates your IP address into a domain name that is human-readable. This is done so that the users can access and view your website through the domain name. This means that there is no need for the users to enter a series of numbers into the browser in order to get to your website.

RAID (Redundancy Array Of Independent Disks) is a phrase you might not frequently come across but it is good to know about it. RAID is the structure that creates the backing of the hard drives through a series of redundant hard disks that store your data. This data can be utilized in case your operating hard drive malfunctions due to any reason.

The method that enables you to condense the data between network protocols is known as tunneling. A common type of the tunneling method is the secure SSH. SSH enables you to tunnel a wide range of protocols in order to provide efficient and secure file transfers and connections.

With proper understanding of the important terminology mentioned above, you will be in a better position to use the dedicated server hosting solution to the best of its capacity.

 

How To : Install NVIDIA 337.19 Beta Graphics Drivers in Ubuntu/Linux Mint Systems

     The latest version of Nvidia Graphics driver for Linux which is Nvidia 337.19 has been released and is available for download. It comes with plenty of fixes and changes. This article will guide you to install Nvidia 337.19 Beta in Ubuntu and Linux Mint systems.

 

Fixes

  • Fixed a bug causing mode validation to fail for 4K resolutions over HDMI in certain situations.
  • Added nvidia-settings command line controls for over- and under-clocking attributes. Please see the nvidia-settings(1) manual page for more details.
  • Fixed several cosmetic issues in the clock control user interface of nvidia-settings.
  • Added support for the GLX_EXT_stereo_tree extension. For more details, see the extension specification: http://www.opengl.org/registry/specs/EXT/glx_stereo_tree.txt
  • Enabled support for using Unified Back Buffer (UBB) and 3D Stereo with the composite extension on Quadro cards. Using stereo with a composite manager requires a stereo-aware composite manager. Otherwise, only the left eye of stereo applications will be displayed. See the GLX_EXT_stereo_tree extension specification for more details.

Read more at YourOwnLinux

 

Fix low resolution grub and splash screen with Nvidia drivers on Ubuntu 14.04

Nvidia drivers With the Nvidia official drivers you are able to throttle the performance of the nvidia graphic cards (gpu) to the maximum. However there are small glitches that need to manually fixed. After installing and enabling the nvidia proprietory drivers you would notice that the grub screen and the Ubuntu splash screen (called Plymouth at startup and shutdown are displaying in a low resolution graphics mode. It is generally as low as 640x480 px. The low resolution is caused because...
Read more... Comment (0)
 

How to install Virtualbox guest additions on Xubuntu 14.04

After installing Xubuntu inside virtualbox, you need to install the guest additions to get better hardware functionality inside it. These include full screen resolution, mouse wheel and pointer integration, copy paste from host os (shared clipboard), shared folders etc. There are 2 ways to install the virtualbox guest additions on Xubuntu. The first method is easy and you just need to install a package from synaptic while the second method is to compile it. The second method is easy...
Read more... Comment (0)
 

Install XBMC 13.0 On Ubuntu / LinuxMint / ElemetaryOS

XBMC Media Center an open source and an award winning media player available for Linux operating systems and also available for other operating systems Windows , OS X.

XBMC allows you to play all popular audio & video formats like MP3,MP4,FLAC, WAV,WMA,OGG, AVI, MKV,MPEG-2,DIVX,XVID and etc

Step 1: Add the Official PPA
sudo add-apt-repository ppa:team-xbmc/ppa
Step 2:update the Repository
sudo apt-get update
Step 3: Install XBMC 13.0 Gotham
sudo apt-get install xbmc

More details visit Source website

 

kmousetool and dragon naturally speaking for RSI

I'm currently using windows 7, but I am seriously thinking of switching over to linux.  Ubuntu seems like a good place to start and seems to be one of the most popular distributions.  Like a lot of people I'm becoming increasingly unhappy with windows, especially the support for XP ending, and the complete mess up of the start menu in windows 8.  I'm also looking at installing on my mother's 10 year old laptop, as that has really slowed down after the support ending for XP.  But my mother is not in any way technical like myself.

There are one or two sticking points for me though.  I have repetitive strain injury and currently use nib autoclick software.  I've been looking at kmousetool and managed to get left click right click and double click working OK, but can't seem to figure out the click and hold.  Also once I've got the programme started and running in the background, I can't get the settings up.  Do you have to leave the settings page open while you're using the program?  I would also like to know how easy it is to highlight text using the click and hold?

The second thing is using dragon naturally speaking in wine.  How easy is this to install?  Can the speech recognition be opened quickly and the text copied and pasted from the dragon pad in wine, to the main desktop environment?  I've had a look on the wine forum and version 10 seems to work the best.

Just one more thing when you install software that is outside the main software centre, like skype for example, does that slow things down and do any upgrades come from the software centre or would they come from skype?

Thank you for your help

Regards

Ryan 

 

 

 

 
Page 5 of 138

Upcoming Linux Foundation Courses

  1. LFD320 Linux Kernel Internals and Debugging
    04 Aug » 08 Aug - Virtual
    Details
  2. LFD405 Embedded Linux Development with Yocto Project
    04 Aug » 07 Aug - Santa Clara, CA
    Details
  3. LFD312 Developing Applications For Linux
    18 Aug » 22 Aug - Virtual
    Details

View All Upcoming Courses


Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board