Pages

Showing posts with label Automatically. Show all posts
Showing posts with label Automatically. Show all posts

How To Mount A Hard Drive Automatically During Start up In Ubuntu

I do not know how many times I will ever receive requests such as “ Hello, how can I automatically mount a hard disk boot Ubuntu? ”. Finally I managed to find some ‘time to write this article I will show you the steps necessary to ensure that, in a completely automatic, power up your Ubuntu are also mounted hard drive or hard drive you need . Let’s start with a first method , longer and more cumbersome, but you will have full control of what you are doing. Open the terminal and type:

sudo mkdir / media / namepersonaldetails

Of course replace “ namepersonaldetails ”with a name to your liking. With this command we are not doing is create a directory under / media where we will mount our hard drive.Now comes the slightly more difficult to know the name of your HD (/ dev/sda2 / dev/sda3, etc.). You can do this from a terminal type the command:

sudo fdisk-l

or the command:

df-h

Now we have to edit the fstab file is a configuration file used to indicate which and how many drives loaded at boot time, with their options. Enter, therefore, the following command:

sudo nano / etc / fstab

and, at the end of the file, add:

/ Dev/sda3 / media / namepersonaldetails ntfs auto, rw, exec, users, dmask = 000, fmask = 111, nls = utf8 0 0

As you can see it, in this case, a HD with NTFS file system. To check that the HD is really mounted, type:

sudo mount-a

Another effective method , and very fast, is to create a small startup script. Type:

gedit ~ / mount.sh

and paste the following code:

# / Bin / sh 
gvfs-mount-d / dev / sdaX

Where, of course, instead of sdaX you need to put the id of your HD. Now granted execute permissions to this script:

chmod + x ~ / mount.sh

And add it to “ boot applications ”in Ubuntu. All very simple, do not you think?

Read more >>

How To Install Automatic Updates Automatically In Ubuntu

Just a few days ago, a user of the blog asked me how it was possible to enable the automatic installation of updates for Ubuntu, without user intervention . In the past there I signaled that it was possible to automatically update the latest security updates and now we shall see how to install all updates in a totally automated . To update your system with the latest software is a good practice, however, not everyone can keep up with this routine. In fact, on Windows, the automatic update is enabled by default.

This short tutorial will show you how to enable automatic software updates and packages in Ubuntu. In this way, you will not need to remember to update the system and all updates are automatically downloaded and installed when the PC is connected to the Internet . This is a great way to make sure that all security patches and software enhancements are automatically installed on your system.

Open the terminal and type:

sudo apt-get install unattended-upgrades

Now type:

sudo gedit / etc/apt/apt.conf.d/10periodic

Edit the file contents to the text shown below:

APT:: Periodic:: Enable "1" 
APT:: Periodic:: Update-Package-Lists "1" 
APT:: Periodic:: Download-Upgradeable-Packages "1" 
APT:: Periodic:: AutocleanInterval "5 " 
APT:: Periodic:: Unattended-Upgrade "1" 
APT:: Periodic:: RandomSleep "1800";

Now, type in terminal:

sudo gedit / etc/apt/apt.conf.d/50unattended-upgrades

and edit the contents of the file with the following code:

Unattended-Upgrade:: Allowed-Origins { 
"} $ {distro_id stable", 
"$ {} $ {distro_id distro_codename-security}" 
"$ {} $ {distro_id distro_codename}-updates", 
/ / "$ {} distro_id $ {} distro_codename-proposed ", 
/ / "$ {} $ {distro_id distro_codename}-backports";

};

Unattended-Upgrade:: Remove-unused-Dependencies "true";

Now install cron-apt:

sudo apt-get install cron-apt

His edit the configuration file:

sudo nano / etc / cron.d / cron-apt

And now edit the file according to your needs!

Read more >>
Next Post