Pages

Showing posts with label bash. Show all posts
Showing posts with label bash. Show all posts

Tuesday, September 21, 2021

Using linux' find command

Strangely enough I sometimes have a need to find a file which I don't know exactly where is. Even though I am sure I am the only one with this problem I will try to explain how to search for a file on my computer.

To make this a rather short how-to I will only give some pointers about using the find-command.

Friday, November 10, 2017

Getting stats from dd -command

While trying to move the contents of one partition to another I used the dd -command like this:
(DO NOT cut'n'paste this command)

dd if=/dev/sda7 of=/dev/sda1

Here's how to get the progress of a long dd-copy:
  1. Open up a terminal (T1) and run your dd-command.
  2. Open another terminal (T2) by pressing Ctrl+Shift +T
  3. In terminal T2 type in: ps aux | grep dd
  4. Find the Pid for the dd-command
  5. In terminal T2 type: kill -USR1 <pid>
  6. Go back to T1 to see the stats printed.

Repeat points 5 and 6 to keep getting an update.

Tuesday, March 31, 2015

Remmina connection problem

After the latest update on my Ubuntu 14.04 Remmina would not connect to one of my Windows computers. I remembered having had this problem before, but was not able to remember the solution. (Even though I knew the solution was a very simple one.)

So I started googling and after a while I found the very simple solution to this problem.

Friday, March 13, 2015

LVM Snapshot example

If your Linux is using LVM (Logical Volume Management) testing out or setting up can be much safer if you take a snapshot of your root partition. Here's a small but helpful example to help you do this quickly.

Friday, March 7, 2014

Cleaning out linux-image-x.x.xx-xx-* files

I was suddenly denied access to my in-house web-server with a message telling me the disk is full. After a quick check with df -h I could confirm the root partition used 100%.
First I started to look for "user -files" I could remove, but found out there wasn't all that many of them. Most of the usage was in the folders /lib, /usr and /var. A quick question to my friend google took me in the direction that there could be some linux-image files no longer used that were spending my disk.
Some more searching gave me the following solution to removing these unused kernel files:

Thursday, January 23, 2014

Making or burning ISO images

I was given a burned CD from a friend and decided to make an ISO image of that particular CD. Currently I'm using Ubuntu 12.10 and decided to use the Linux-command: dd

But to my surprise; IT WOULDN'T WORK!!! I have always used that command to make an ISO image, so now I had to figure out why this is not working, and how I could make it work.

Tuesday, December 11, 2012

find files between two dates

Here's a quick tip for how you can find a file between two dates.
Suppose you are looking for a file you know you worked with last friday. At the time of writing this would be on december 7th. Using the find command you can go to your terminal and add the following code:


find . -type f -newerat "2012-12-07" -not -newerat "2012-12-08"


This would search for files acessed between dec. 7th and dec. 8th.
This code snippet also shows an example of how to use the -newerXY parameter of the find -command.

Saturday, July 21, 2012

Linux Tutorials

Linux has become the preferred OS for me and my company. Not only for the fact that it is free, but also because of the possibilities it gives us.

For a small company as ours Linux is the perfect solution. It provides us with a stable and secure platform for our servers running mail, webserver, fileserver, printserver, automated backups and a lot more.

Of course we need to know a thing or two about installing it and setting up the various components . And I am always looking for more information on how to configure and setup different parts of Linux and other Open Source Software.

Recently I found out that linux.org had redesigned their site and of course I had to take a look at it.