Swap appears to not be in use

(I am currently using Ubuntu 14.04 LTS, GNOME environment) **tl;dr** How can I force more memory swapping (swappiness already at 100)? I have recently been experiencing a lot of system freezes/crashes. Often when accessing busy websites. It has been happening so much I have htop loaded on my tty, so I can switch to it and terminate my browser (as GUI does not respond). However, sometimes I need to use REISUB. I thought GNOME might work better than Unity, as my Debian system has no problems, and it did to a point, but I am still running high on memory, and getting freezes. I looked at my `free -m` today, and noticed my swap was showing 0 used. Output:                            total       used       free     shared    buffers     cached     Mem:          1821       1673        148        221         40        643     -/+ buffers/cache:        989        832     Swap:         1933          0       1933      ` I did a temporary swappiness to 100 (`sudo sysctl vm.swappiness=100`). The results were still the same (0 being used even after running to near max system memory usage). I looked at this answer: How do I see if system is swapping? unfortunately as I am writing this, my system went into updates, and my packages are locked, so I cannot install this (`sar`) nor am I sure what package this is part of, in order to give another Output. I have looked in the fstab, and my swap partition is being used correctly.               # swap was on /dev/sda3 during installation      UUID=10fdfed2-1fde-4d9f-a8f1-3d2376b0ffcc none            swap    sw              0       0      I am using a shared swap partition with my Debian OS (dual boot, separate partition, shared swap). But the partition is not locked, and I did a quick `swapoff ...`, `swapon ...`, and `swapon -s` to see if it would possibly recognize my swap and start swapping. It appears to still be at low swapping (84 hooray), but my memory usage is at 90%+ usage. With around 13% memory usage by Chromium, 17% by GNOME. I don't care if I am forced into slowness, but I can't be forced into full system freeze (can't access TTY, can't do `Ctrl`+`Alt`+`Backspace`, only `Alt`+`SysReq` R,E,I,S,U,B) I had the same issue with 12.04 LTS (pre-packaged), but have recently gone to 14.04 LTS. Bottom Line: How can I force swapping further, and/or control processes before they cause system stability issues? (Side Note: Debian works fine, except for mouse touchpad issue) Output of `dmesg | grep error`:               [   26.646691] EXT4-fs (sda2): re-mounted. Opts: errors=remount-ro      This is Ubuntu Partition. Same error on Debian Partition except sda7.


enable networking inside a freebsd jail

So I'm mostly a linux newbie itself. Let alone freebsd, so please bear with me. I just need some very basic clues to get this to work. I use **FreeBSD 9.1 64-bit** from the list here. On my freebsd amazon instance, I have a jail running :               # jls      JID  IP Address      Hostname                      Path      1  192.168.1.101   01.gideon.com                /jails/01.gideon.com      If I goto that jails console I can't install perl on it. (If I do portsnap fetch **inside the jail** I get : `host: isc_socket_bind: address not available` and then it says _no mirrors, giving up._ ) I've looked at several articles and posts but I'm confused about what goes where, I just want you to tell me where I should put the right entries, this is a sample from this article, my system info is below:               rc.conf     hostname="" #what goes here?     defaultrouter=""#what goes here?     #I don't understand what this is for?     ifconfig_em0="inet 192.168.0.10 netmask 255.255.255.0"          #I'm guessing this should be like this:     ifconfig_xn0="inet 192.168.1.101 netmask 255.255.255.0"          # Should I use an alias?     # ifconfig_em0_alias0="inet 192.168.0.111 netmask 255.255.255.0"      This is what `ifconfig -a` gives me:               lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384             options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>             inet6 ::1 prefixlen 128             inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1             inet 127.0.0.1 netmask 0xff000000             nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>     xn0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500             options=503<RXCSUM,TXCSUM,TSO4,LRO>             ether 12:31:39:2a:dc:cc             inet 10.8.106.58 netmask 0xfffffe00 broadcast 10.8.107.255             nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>             media: Ethernet manual             status: active      This is my `/etc/resolve.conf`:               # Generated by resolvconf     search ec2.internal     nameserver 172.16.0.23      So how do I go about this?


How to execute script on logging out?

I'm reading The Unix Programming Environment. There is an exercise question to print how much CPU time you have consumed when you log off by editing `.profile`. I tried with this               trap 'times' 0 1 2 15      but it is not working.


What exactly does rmdir -p do?

> -p, --parents remove DIRECTORY and its ancestors; e.g., `rmdir -p a/b/c' is > similar to`rmdir a/b/c a/b a' Yeah - I'm definitely not going to risk testing that out myself. ;)


Ctrl+a+d exiting terminal?

I don't know what I have changed, but if I am on a terminal and I press `Ctrl+a+d` (that is, the three keys simultaneously) the terminal is killed. This is on `gnome-terminal` on `Ubuntu` and using `zsh` as the default login shell. I checked the keyboard shortcuts on `gnome-terminal` (on the GUI, under `Edit->Keyboard Shortcuts`) and searched for `bindkey` statements that may trigger this undesired shortcut in my home directory but found nothing. I am pretty sure that this is new behavior (last couple of days) since I frequently type `Ctrl-a` to go to the beginning of a line on my terminal and then `Ctr-d` to delete characters, and if I do this at the moment, it triggers this undesired keyboard shortcut. I recently installed some system updates, but I'd be surprised if these updates changed shortcuts. At the moment I have no clue why this is happening, so any help will be greatly appreciated. **Note:** This only happens on terminals. If I am on some other app, `Ctrl+a+d` does not trigger any exit commands.


Launch process as another user/group (in init.d script)

I am editing a init.d script. The init.d script runs a utility script which then runs an process. From either bash scripts how would I make it launch the main process as a specific user and group?


Dynamic wallpaper change on CentOS 6.3

Is there any possible way to change wallpaper (background) every five minutes on centos 6.3 with gnome 2.28.2 ? I found this Python script:               #!/usr/bin/env python          import gobject     gobject.threads_init()     import gtk     import os     import xml.dom.minidom     import gconf          class Wallpaper:         def __init__(self):             # Create GTK Window             self.window = gtk.Window(gtk.WINDOW_TOPLEVEL)             self.window.set_title("Dynamic Wallpaper")             self.window.resize(350, 110)             self.window.set_resizable(False)                  # Create window objects             vbox = gtk.VBox()                  label = gtk.Label("Folder:")             label.set_alignment(0.0, 0.5)             self.folder_entry = gtk.Entry()             button = gtk.Button("Select...")             button.connect("clicked", self.button_clicked)             hbox = gtk.HBox()             hbox.pack_start(label, True)             hbox.pack_start(self.folder_entry, False)             hbox.pack_start(button, False)             vbox.pack_start(hbox, False)                  label = gtk.Label("Picture duration:")             label.set_alignment(0.0, 0.5)             adj = gtk.Adjustment(5.0, 1.0, 60.0, 1.0, 1.0, 0.0)             self.pdur_spinner = gtk.SpinButton(adj)             self.pdur_combo = gtk.combo_box_new_text()             self.pdur_combo.append_text("hr")             self.pdur_combo.append_text("min")             self.pdur_combo.append_text("sec")             self.pdur_combo.set_active(1)             hbox = gtk.HBox()             hbox.pack_start(label, True)             hbox.pack_start(self.pdur_spinner, False)             hbox.pack_start(self.pdur_combo, False)             vbox.pack_start(hbox, False)                  label = gtk.Label("Transition duration:")             label.set_alignment(0.0, 0.5)             adj = gtk.Adjustment(5.0, 0.0, 60.0, 1.0, 1.0, 0.0)             self.tdur_spinner = gtk.SpinButton(adj)             self.tdur_combo = gtk.combo_box_new_text()             self.tdur_combo.append_text("hr")             self.tdur_combo.append_text("min")             self.tdur_combo.append_text("sec")             self.tdur_combo.set_active(2)             hbox = gtk.HBox()             hbox.pack_start(label, True)             hbox.pack_start(self.tdur_spinner, False)             hbox.pack_start(self.tdur_combo, False)             vbox.pack_start(hbox, False)                  self.cancel_button = gtk.Button(stock=gtk.STOCK_CLOSE)             self.cancel_button.connect("clicked", self.destroy)             self.ok_button = gtk.Button(stock=gtk.STOCK_OK)             self.ok_button.set_sensitive(False)             self.ok_button.connect("clicked", self.ok_button_clicked)             hbox = gtk.HBox()             hbox.pack_end(self.ok_button, False)             hbox.pack_end(self.cancel_button, False)             vbox.pack_end(hbox, False, False, 10)                  # Connect signal handlers             self.window.connect("delete-event", self.delete_event)             self.window.connect("destroy", self.destroy)                  # Show entire window             self.window.add(vbox)             self.window.show_all()              def destroy(self, widget):             gtk.main_quit()              def button_clicked(self, button):             dialog = gtk.FileChooserDialog("Open..", None, gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER,                                            (gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL,                                             gtk.STOCK_OK, gtk.RESPONSE_OK))             dialog.set_default_response(gtk.RESPONSE_OK)             dialog.set_filename(os.path.expanduser("~/Pictures/*"))             response = dialog.run()             filename = dialog.get_filename()             dialog.destroy()                  if response == gtk.RESPONSE_OK:                 self.folder_entry.set_text(filename)                 self.files = []                 accepted = ('.jpg', '.jpeg', '.gif', '.png')                 for file in os.listdir(filename):                     if os.path.splitext(file)[1] in accepted:                         self.files.append(os.path.join(filename, file))                      if len(self.files):                     self.ok_button.set_sensitive(True)                 else:                     dialog = gtk.MessageDialog(parent = None, flags = gtk.DIALOG_DESTROY_WITH_PARENT,                         type = gtk.MESSAGE_ERROR, buttons = gtk.BUTTONS_OK,                         message_format = "Folder contains no images")                     dialog.set_title('Error')                     dialog.connect('response', lambda dialog, response: dialog.destroy())                     dialog.run()              def ok_button_clicked(self, button):             nfiles = len(self.files)                  if nfiles <= 0:                 return False                  folder = self.folder_entry.get_text()                  picture_duration = int(self.pdur_spinner.get_text())             if self.pdur_combo.get_active_text() == "min":                 picture_duration = picture_duration * 60             elif self.pdur_combo.get_active_text() == "hr":                 picture_duration = picture_duration * 60 * 60                  transition_duration = int(self.tdur_spinner.get_text())             if self.tdur_combo.get_active_text() == "min":                 transition_duration = transition_duration * 60             elif self.tdur_combo.get_active_text() == "hr":                 transition_duration = transition_duration * 60 * 60                  document = """<background><starttime><year>2009</year><month>08</month><day>04</day><hour>00</hour><minute>00</minute><second>00</second></starttime></background>"""             dom = xml.dom.minidom.parseString(document)                  for i in range(0, nfiles):                 static = dom.createElement("static")                 duration = dom.createElement("duration")                 duration.appendChild(dom.createTextNode(str(picture_duration)))                 static.appendChild(duration)                 file = dom.createElement("file")                 file.appendChild(dom.createTextNode(self.files[i]))                 static.appendChild(file)                 dom.documentElement.appendChild(static)                      if transition_duration <= 0: continue                      transition = dom.createElement("transition")                 duration = dom.createElement("duration")                 duration.appendChild(dom.createTextNode(str(transition_duration)))                 transition.appendChild(duration)                 frm = dom.createElement("from")                 frm.appendChild(dom.createTextNode(self.files[i]))                 transition.appendChild(frm)                 to = dom.createElement("to")                 if i < nfiles-1:                     to.appendChild(dom.createTextNode(self.files[i+1]))                 else:                     to.appendChild(dom.createTextNode(self.files[0]))                 transition.appendChild(to)                 dom.documentElement.appendChild(transition)                  try:                 save_filename = os.path.join(folder, "background-1.xml")                 f = open(save_filename, 'w')                 f.write(dom.toxml("utf-8"))                 f.close()             except IOError as (errno, strerror):                 try:                     save_filename = os.path.join(os.path.expanduser("~"), ".dynamic-wallpaper.xml")                     f = open(save_filename, 'w')                     f.write(dom.toxml("utf-8"))                     f.close()                 except Error as (errno, strerror):                     dialog = gtk.MessageDialog(parent = None, flags = gtk.DIALOG_DESTROY_WITH_PARENT,                         type = gtk.MESSAGE_ERROR, buttons = gtk.BUTTONS_OK,                         message_format = strerror)                     dialog.set_title('Error')                     dialog.connect('response', lambda dialog, response: dialog.destroy())                     dialog.run()                     return False             except Error as (errno, strerror):                     dialog = gtk.MessageDialog(parent = None, flags = gtk.DIALOG_DESTROY_WITH_PARENT,                         type = gtk.MESSAGE_ERROR, buttons = gtk.BUTTONS_OK,                         message_format = strerror)                     dialog.set_title('Error')                     dialog.connect('response', lambda dialog, response: dialog.destroy())                     dialog.run()                     return False                  backgrounds_file = os.path.join(os.path.expanduser("~/.gnome2/"), "backgrounds.xml")             doc = xml.dom.minidom.parse(backgrounds_file)                  wallpaper = dom.createElement("wallpaper")             wallpaper.setAttribute("deleted", "false")             name = dom.createElement("name")             name.appendChild(dom.createTextNode("Dynamic Wallpaper"))             filename = dom.createElement("filename")             filename.appendChild(dom.createTextNode(save_filename))             options = dom.createElement("options")             options.appendChild(dom.createTextNode("stretched"))             shade_type = dom.createElement("shade_type")             shade_type.appendChild(dom.createTextNode("solid"))             pcolor = dom.createElement("pcolor")             pcolor.appendChild(dom.createTextNode("#2c2c00001e1e"))             scolor = dom.createElement("scolor")             scolor.appendChild(dom.createTextNode("#2c2c00001e1e"))             wallpaper.appendChild(name)             wallpaper.appendChild(filename)             wallpaper.appendChild(options)             wallpaper.appendChild(shade_type)             wallpaper.appendChild(pcolor)             wallpaper.appendChild(scolor)             doc.documentElement.appendChild(wallpaper)                  try:                 f = open(backgrounds_file, 'w')                 f.write(doc.toxml("utf-8"))                 f.close()             except Error as (errno, strerror):                     dialog = gtk.MessageDialog(parent = None, flags = gtk.DIALOG_DESTROY_WITH_PARENT,                         type = gtk.MESSAGE_ERROR, buttons = gtk.BUTTONS_OK,                         message_format = strerror)                     dialog.set_title('Error')                     dialog.connect('response', lambda dialog, response: dialog.destroy())                     dialog.run()                     return False                  conf_client = gconf.client_get_default()             conf_client.add_dir("/desktop/gnome/background", gconf.CLIENT_PRELOAD_NONE)             conf_client.set_string("/desktop/gnome/background/picture_filename", save_filename)             conf_client.set_string("/desktop/gnome/background/picture_options", "strecthed")             conf_client.set_string("/desktop/gnome/background/color_shading_type", "solid")             conf_client.set_string("/desktop/gnome/background/primary_color", "#2c2c00001e1e")             conf_client.set_string("/desktop/gnome/background/secondary_color", "#2c2c00001e1e")                  gtk.main_quit()              def delete_event(self, widget, event):             return False          if __name__ == "__main__":         wallpaper = Wallpaper()         gtk.main()      The script is for Ubuntu and when I ran it on my system and it generate a xml file but it doesn't work. Can anybody help me? Best regards, George! **Postscript** : And sorry for my awful English...


Change routes for VPN

I need to use for some things a cisco VPN connection, but I don't want to route all my trafic over the VPN but only that traffic, that is send to a specific network. How does a script look like, that sends all traffic to 10.10.3.1 or exchange.server.de through the VPN tunnel and the rest of the traffic uses the default route that existed before the VPN was established? Thanks for your help.


External Hard-Drive not visible in /media

I cannot seem to ssh into my external Hard-drive on "/media" it used to show up there, but now it doesn't. I have erased the Disk and verified it (on MAC OSX) and it still does not show. I have executed the command "lsusb" and got the following: > 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub > > Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. > > Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. > > Bus 001 Device 004: ID 0bc2:3312 Seagate RSS LLC This looks fine to me, as though it is picking it up, however, now showing the drive. Does anyone know what could be the problem? EDIT: fdisk -l output:               Disk /dev/sda: 2000.4 GB, 2000398933504 bytes     255 heads, 63 sectors/track, 243201 cylinders, total 3907029167 sectors     Units = sectors of 1 * 512 = 512 bytes     Sector size (logical/physical): 512 bytes / 512 bytes     I/O size (minimum/optimal): 512 bytes / 512 bytes     Disk identifier: 0x00000000     Device Boot      Start         End      Blocks   Id  System     /dev/sda1               1  3907029166  1953514583   ee  GPT      blkid output:               /dev/mmcblk0p1: SEC_TYPE="msdos" UUID="3312-932F" TYPE="vfat"      /dev/mmcblk0p2: UUID="b7b5ddff-ddb4-48dd-84d2-dd47bf00564a" TYPE="ext4"      /dev/sda1: LABEL="EFI" UUID="70D6-1701" TYPE="vfat"      /dev/sda2: UUID="ae48face-7d6e-3ce9-9f8c-77d8a605d00a" LABEL="Untitled" TYPE="hfsplus"


How do I cd up and down again with symlinks in bash?

Structure:               /base/        +- somedir/        +- symlink/  -> /some_other_dir      This command (in addition to my Makefiles) fails:               cd /base/symlink     ls ../somedir      Bash complains that ../somedir does not exist. Likewise, my makefiles in some_other_dir that reference ../somedir fail. However, cd .. works just as expected. Can I have my shell act with regards to the logical structure?


usermod -d /path user - User is currently logged in

good Day I want to make a change to a user on my CENTOS server. I want to change his default directory. When running the command:               usermod -d /path_to_new_dir david      terminal gives me the following               User david is currently logged in      I closed all ftp sessions which I was engaged into with that user, and I am logged into terminal as root. How do I run that command and how do I log out the user? As far as I am concerned he is not logged in...


lshw and lscpu disagree on caches - which is right?

I am trying to find out specifics about caches (in particular which caches are shared between cores and which are not) and have stumpled onto a inconsistency. `sudo lshw` says               *-cache:0          description: L1 cache          physical id: a          slot: Internal Cache          size: 64KiB          capacity: 64KiB          capabilities: synchronous internal write-back     *-cache:1          description: L2 cache          physical id: b          slot: External Cache          size: 8MiB          capabilities: synchronous internal write-back      but `lscpu` claims               L1d cache:   32K     L1i cache:   32K     L2 cache:   256K     L3 cache:  8192K      I do not worry too much about instruction and data cache being added together, but where did L2 go? Observed on a machine running Ubuntu 10.10, or to let `uname -a` speak:               Linux name 2.6.35-32-generic #66-Ubuntu SMP Mon Feb 13 21:04:32 UTC 2012 x86_64 GNU/Linux      This is a general question, but note that neither the most precise manufacturer spec I could find nor Wikipedia do have the necessary detail. Unrelated bonus question: does `External Cache` mean the cache is shared between the (four) cores (and `Internal Cache` the opposite)?


personal document management system

I'm looking for a personal document management system that would:   * track changes in documents in a configured directory tree   * save new files to a content repository (thus allowing of their versioning)   * offer some kind of web gui for browsing the repository - ideally it would allow tracking changes in documents etc The files I'd like it to support are:   * microsoft word files (doc, docx, xls)   * open office files   * pdf files   * txt files I've looked through a couple of such systems (DMS-grade) but haven't noticed them having the autonomous scanning option. What I'd like to have is a unobtrusive solution that wouldn't require users to upload documents through web gui. All the versioning, backing up stuff should be transparent to them. Only if they were actually interested in downloading the older version they would fire up the web gui. Any comments and suggestions are welcomed.


Symbolic link starting with .#

I have a symlink in one of my directories that has the following name:               lrwxrwxrwx  1 XXXX ZZZ   37 Jan 15 18:18 .#perl.org -> XXX@YYY.com.2980:1344441539      I am wondering what this symlink represents and which program/action created it. By the way, I have a file in this directory called `perl.org` that I have been working on for the last few days. I connect with `ssh -Y` and then run `emacs` to edit this and other files.


Wicd and NetworkManager both not working in Debian Jessie

I recently installed Debian, and I was able to get the WiFi to work using the command line. After a while, it stopped working. I figured that it had something to do with the fact that my intel iwlwifi driver is proprietary and had to be installed separately. It wasn't until I installed NetworkManager over ethernet that I realized that I had accidentally used a hardware switch to disable my WiFi (haha). I still had some problems though, so I decided to reinstall the system. This time, I immediately upgraded to Jessie (currently testing) to see if it would fix things. Everything works fine when I connect to WiFi using the command line. However, I was tired of always having to connect manually, so I installed NetworkManager. The problem is, it wasn't showing available networks. At one point, it did, but when I tried to connect, it just told me that I had the wrong password. I figured that NM just didn't want to work with Xfce (for whatever reason), so I gave Wicd a try. This time, it was at least showing me available networks. However, I would try to connect, and it wouldn't connect. I would click `Connection information` and it just said connecting. It never even asked for a password. What I am trying to figure out now, is why I can connect manually, but anytime I try to use some sort of network manager, it doesn't work. I would post error messages, but to be honest, I am not really sure where wicd puts them. I am currently trying to fix Wicd, since it seemed to work better than NM. Although I wouldn't mind using anything at this point, as long as it works. I really want to get this working, as I have been working on it for at least two weeks, and everything else is working pretty nicely.


How can I install Arch Linux on a Laptop with Intel GMA 4500 MHD?

I would like to install Arch Linux on my Acer TravelMate 5735Z. Sadly, it has a Intel GMA 4500 MHD graphic card. This means, I suffer from Kernel Bug [GM45] black screen at boot (0 backlight?). When I boot from the installation CD for Arch Linux 2013.10.01, I can see the menu that lets me choose to install arch/boot the installed system (Ubuntu 10.04, I think)/Power off. But when I choose to install Arch, the screen gets black. In this German article, the author seems to have found a solution for Linux Mint. But he begins with "start LiveCD in compatibility mode". As there is no such thing in the Arch Menu, I thought I had to edit the installation parameters. But when I hit tab, I get some cryptic stuff:               . linux boot/x86_64/vmlinuz archisobasedir=arch archisolabel=ARCH_201310 init     rd=boot/x86_64/archiso.img      I only have WLAN, so I can't try a network installation. How can I install Arch Linux on this computer?


How to copy to a formatted image without root privileges?

I have formatted an image file using the `mkfs` command, and I would now like to copy files to that image file without root privileges. I have already tried to mount the image to a local directory, which did require root privileges for some reason. (feel free to comment why) Is there a widely supported way to copy files into a formatted image without requiring root privileges. _Edit:_ The image is formatted as FAT-32.


Minimal Command Line Distro

So, I want to have a VM of a very minimal x86 Linux install, with networking support so I can download packages. All this VM is going to be used for is to learn NASM assembly, since all of the other Linux installs I have anywhere area all x86_64 installs. Thanks!


Augeas not reading all yum.repos.d files. Why?

I'm trying to use Augeas to manage some options in yum.repos.d but it's not reading all repo files in there. Any hint?               # ls -l /etc/yum.repos.d/     total 24     -rw-r--r-- 1 root root  200 Nov 10 15:50 3rd.repo     -rw-r--r-- 1 root root  279 Sep 10 14:21 Citrix.repo     -rw-r--r-- 1 root root  172 Nov 10 16:17 epel.repo     -rw-r--r-- 1 root root  172 Nov 10 15:21 ius.repo     -rw-r--r-- 1 root root 1308 Nov 10 15:21 os.repo      And in augtool:               # augtool ls /files/etc/yum.repos.d/     os.repo/ = (none)     Citrix.repo/ = (none)      Trying to debug in augtool:               # augtool ls /augeas/files/etc/yum.repos.d/     os.repo/ = (none)     Citrix.repo/ = (none)      Thanks in advance!


How to clear terminal after logging out?

Currently on my laptop when I log out I can still see traces of my last activities (in tty). How can I tell it (Gentoo) to clear the screen before logging out?


Mount USB (FAT) in Gentoo

Can somebody show me how to make Gentoo mount my USB? This is what I got when trying `mount /dev/sdb1 /mnt`: > mount: wrong fs type, bad option, bad superblock on /dev/sdb1, missing > codepage or helper program, or other error In some cases useful info is > found in syslog - try dmesg | tail or so `dmesg` says: > FAT: codepage cp437 not found


Is there any way for group "owners" to have full rights of a file or directory owner?

Is it possible with the normal Unix permissions system to enable group members to have the right to change a file's permissions? In other words, suppose we have a file `awesome.rb` which is owned by user `brandon` who belongs to group `developers`, and user `darryl` (also a member of `developers`) needs to make a particular file executable. Is there any way to make this possible?


Installing Ossec on an existing centos 6.4 machine

I have an existing machine running centos 6.4. Is it ok to install now the Ossec or it's not worth any more as the machine is already running for few months. Which is the best mechanism to install because I saw one is from the source and some recommend atomicorp repo? Any recommendation please?


Debian's ReportBug equivalent on Fedora/Gnome?

When I was using Debian, there was a tool called "ReportBug" - or something like that. Ironically, the tool itself was probably the buggiest program I have ever used. I was never, ever actually able to make a successful bug report in the graphical mode. However, the tool seems to be a good idea. I don't have to go through some online identification process, or do any browser-business - I'd just fire up a program, fill out a few forms, and that was it. Is there something like that for the Fedora operating system? Or for Gnome itself? Because, sometimes, I encounter weird bugs and errors, and I think it would come in handy to have such a tool at my fingertips.


Problem compiling a driver : "No rule to make target"

First of all I am running a CentOS 6.4 installation. My computer is a laptop and I am trying to install the drivers for my ethernet card, because this week end I lost my ability to connect to the Internet. So I downloaded the driver : jmebp-1.0.8.5 I installed gcc, kernel-devel and since it wasn't working I finally installed the group Development Tools (in case I had forgot something). When I               make install      I get this error :               *** No rule to make target `internet/jmebp-1.0.8.5'.  Stop.     Leaving directory `/lib/modules/2.6.32-358.6.1.el6.x86_64/build'      My makefile is :                   MODNAME := jme     obj-m := $(MODNAME).o          ifneq ($(KERNELRELEASE),)     #########################     # kbuild part of makefile     #########################     EXTRA_CFLAGS += -Wall -O3     #EXTRA_CFLAGS += -DTX_DEBUG     #EXTRA_CFLAGS += -DREG_DEBUG          else     #########################     # Normal Makefile     #########################     TEMPFILES := $(MODNAME).o $(MODNAME).mod.c $(MODNAME).mod.o Module.symvers .$(MODNAME).*.cmd .tmp_versions modules.order Module.markers Modules.symvers          ifeq (,$(KVER))     KVER=$(shell uname -r)     endif     KSRC ?= /lib/modules/$(KVER)/build     MINSTDIR ?= /lib/modules/$(KVER)/kernel/drivers/net          all: modules         @rm -rf $(TEMPFILES)     modules:         @$(MAKE) -C $(KSRC) M=$(shell pwd) modules          checkstack: modules         objdump -d $(obj-m) | perl $(KSRC)/scripts/checkstack.pl $(shell uname -m)         @rm -rf $(TEMPFILES)          namespacecheck: modules         perl $(KSRC)/scripts/namespace.pl         @rm -rf $(TEMPFILES)          install: modules         install -m 644 $(MODNAME).ko $(MINSTDIR)         depmod -a $(KVER)          patch:         @/usr/bin/diff -uar -X dontdiff ../../trunc ./ > bc.patch || echo > /dev/null          buildtest:         SRCDIRS=`find ~/linux-src -mindepth 1 -maxdepth 1 -type d -name 'linux-*' | sort -r -n`; \         SRCDIRS="$${SRCDIRS} `find ~/linux-src/centos -mindepth 2 -maxdepth 2 -type d -name 'linux-*' | sort -r -n`"; \         SRCDIRS="$${SRCDIRS} `find ~/linux-src/fedora -mindepth 2 -maxdepth 2 -type d -name 'linux-*' | sort -r -n`"; \         for d in $${SRCDIRS}; do \             $(MAKE) clean && $(MAKE) -C . KSRC=$${d} modules; \             if [ $$? != 0 ]; then \                 exit $$?; \             fi; \         done         $(MAKE) clean          clean:         @rm -rf $(MODNAME).ko $(TEMPFILES)          %::         $(MAKE) -C $(KSRC) M=`pwd` $@          endif      Any suggestions ?


How to setup backup if the filesystem is read only

My remote server file system is read-only & its because my hard disk is broken .I want to take backup for taking any further action.   1. Is it possible to setup a manual backup for the affected server (as its file system is read only).    2. If possible then how to perform or add this affected server to my backup server as client.   3. Or any other possible solution . **NOTE:** This remote server is a VM inside an ESXi server.(i.e. ESXi>Affected Server).


Install Ubuntu partitions

I am a completely newbie. I want to install Ubuntu 14.04 in my laptop on which windows 8.1 is installed. I have read in some sites that I have to use Gparted or similar tools, but there are also sites that don´t this kind of tools, just shrink the volume of C:. What is the difference between using Gparted or similar and not using it, to install Ubuntu for dual boot. Thanks


Activating Audio System in Arch Linux

I wanted to get the audio system going on Arch Linux, and I followed the very concise instruction I found on Archlinux.org, but it didn't help. Has anyone done this personally, therefore knowing the practical shortcut? I'd be glad to know of it. Thank you.


Why can I access to my C: or D: drives from Ubuntu?

Why can I access to my C: or D: drives from Ubuntu when I install Ubuntu 14.04. Why does this happen?


calling library functions from different language

As we know libraries are precompiled codes, so we do not need to compile them. Can we call library functions of one language from a different language?


Mutt: can I define my own rules for quoted message detection?

I recently started using mutt with my gmail IMAP mail address. Because I loved it so much, I also set it up with my college email address. This, sadly, is hosted by the college ICT team under Outlook Webapp, which seems not to adhere to some vary basic standards such as message quoting. On every mail service I've used (not many but hey), a message is quoted using the following method:               This is my new message     >this is      >a quoted message     >> this is a      >> quoted message inside the quoted message      or something similar. Mutt seems to pick this up and colorize them appropriatly. However, the Outlook Webapp has following qutoing scheme:               This is my new message          -----Original Message-----     From: Foo@Bar     Subject: Foobar     Date: 1st of Foo, 2012 20:18     To: Bar@Baz          this is      a quoted message          -----Original Message-----     From: Bar@Baz     Subject: Foobar     Date: 1st of Foo, 2012 20:13     To: Foo@Bar          this is     a quoted message inside the quoted message      Is there a way to tell mutt how to pick this up? Note that when different users have different languages set in the web app this will also reflect in the quoting, eg a Dutch person will have `-----Oorspronkelijk bericht-----` instead of it's english counterpart, and it will be sent around like that. So there will be some mixing up. It feel saddened by the lack of respect for simple standards like this, because they make life so much harder than it has to be. Note: I have renounced using the outlook webapp, and thus I set up a new gmail account. My outlook webmail get's forwarded to this gmail account and I can reply to it using my normal college email adress from the gmail webapp or mutt. The bad quotin remains a problem though.


Fedora 18: can't resolve hosts

My Fedora 18 machine is having problems with resolving hosts: `Could not resolve host: ...; No address associated with hostname]` `HTTP error on [https://lon.auth.api.rackspacecloud.com/v2.0/tokens], curl code [6] message [Could not resolve host: lon.auth.api.rackspacecloud.com; No address associated with hostname]'` How do I fix this?


"Acpi-State" in slabtop's output gets increased — what is it? Is it a bug?

Since boot it gets increased occupying even more RAM than anything else:                Active / Total Objects (% used)    : 680608 / 719176 (94.6%)      Active / Total Slabs (% used)      : 17390 / 17390 (100.0%)      Active / Total Caches (% used)     : 72 / 113 (63.7%)      Active / Total Size (% used)       : 78756.64K / 89892.73K (87.6%)      Minimum / Average / Maximum Object : 0.01K / 0.12K / 8.00K            OBJS ACTIVE  USE OBJ SIZE  SLABS OBJ/SLAB CACHE SIZE NAME                        212109 211201  99%    0.08K   4159       51     16636K Acpi-State     203776 200343  98%    0.06K   3184       64     12736K kmalloc-64      66682  65275  97%    0.18K   3031       22     12124K vm_area_struct       7974   3826  47%    0.88K    443       18      7088K xfs_inode       8596   5811  67%    0.55K    614       14      4912K radix_tree_node      * * * And after several hours it still grows even larger:                Active / Total Objects (% used)    : 699321 / 782632 (89.4%)      Active / Total Slabs (% used)      : 18711 / 18711 (100.0%)      Active / Total Caches (% used)     : 72 / 113 (63.7%)      Active / Total Size (% used)       : 82030.29K / 95484.77K (85.9%)      Minimum / Average / Maximum Object : 0.01K / 0.12K / 8.00K            OBJS ACTIVE  USE OBJ SIZE  SLABS OBJ/SLAB CACHE SIZE NAME                        243933 222506  91%    0.08K   4783       51     19132K Acpi-State     231104 210673  91%    0.06K   3611       64     14444K kmalloc-64      68574  66749  97%    0.18K   3117       22     12468K vm_area_struct       7218   2706  37%    0.88K    401       18      6416K xfs_inode       8498   8123  95%    0.55K    607       14      4856K radix_tree_node


Excessively high disk usage freezes my server

I have a laptop converted to a Linux Mint server running a variety of services. Recently, it started being unaccessible at random. The situation seems intermittent. The server is usually blazing fast. I can still ping the server, but any attempt to access its services (ssh, web, etc) takes a prohibitive amount of time. When I try to access the server with SSH, it can take over 15 minutes before I get to the login screen. The hard drive activity light stays on and the machine is running hotter than usual but not dangerously so. If I reboot the machine, it is super fast for some time, until it randomly becomes unresponsive again, maybe days later. I have tried using `iotop`, but I've spent the past 45 minutes just waiting for it:               user@machine~ $ sudo iotop     [sudo] password for user: debug3: Received SSH2_MSG_IGNORE     debug3: Received SSH2_MSG_IGNORE     debug3: Received SSH2_MSG_IGNORE          debug2: client_check_window_change: changed     debug2: channel 0: request window-change confirm 0      **EDIT** I power cycled the server and took a look at all the logs. These were the last entries in syslog. There were several hundred of identical lines preceding it:               Jul 17 20:35:16 t510-mint pulseaudio[2106]: [pulseaudio] protocol-native.c: Warning! Too many connections (64), dropping incoming connection.     Jul 17 20:35:40  pulseaudio[2106]: last message repeated 673 times     Jul 17 20:35:40 t510-mint rsyslogd-2177: imuxsock begins to drop messages from pid 2106 due to rate-limiting     Jul 17 20:35:41 t510-mint rsyslogd-2177: imuxsock lost 6 messages from pid 2106 due to rate-limiting     Jul 17 20:35:41 t510-mint pulseaudio[2106]: [pulseaudio] protocol-native.c: Warning! Too many connections (64), dropping incoming connection.     Jul 17 20:36:05  pulseaudio[2106]: last message repeated 673 times     Jul 17 20:36:05 t510-mint rsyslogd-2177: imuxsock begins to drop messages from pid 2106 due to rate-limiting     Jul 17 20:36:06 t510-mint rsyslogd-2177: imuxsock lost 6 messages from pid 2106 due to rate-limiting     Jul 17 20:36:06 t510-mint pulseaudio[2106]: [pulseaudio] protocol-native.c: Warning! Too many connections (64), dropping incoming connection.     Jul 17 20:37:19  pulseaudio[2106]: last message repeated 567 times


Can't get out of foreground mode in STunnel

I was trying to debug an STunnel installation on my Raspberry Pi (using Raspbian) and so I set the foreground mode to yes (which is something suggested in the official documentation). Unfortunately, now every time the Raspberry Pi boots up, it will present the log to me in the foreground, with no way for me to run any other command, browse the file system, etc. I tried `Ctrl`+`Z`, but that didn't work. The only thing that seems to work is `Ctrl`+`Alt`+`Delete`, but that just reboots the Raspberry Pi.


How to enable TCP connection in Debian Squeeze?

I need enable TCP connections to my system, for use graphical applications in marionnet, network simulation system, in debian squeeze. In older versions of debian it is achieved with System|Administration|Login Window -> uncheck “Deny TCP connections to the Xserver”. but in squeeze I have no idea. ?? EDIT: I have the answer: take a look here


create multipath for local partition

Is it possible to create multipath to local partition? I got partition /dev/sda3 and I need /dev/mapper/mpath01 to be pointing to it. This is what I added in my kickstart (rhel 5.7)               part /my_mount_point --size=2500 --ondisk=sda --fstype ext3     multipath --name=mpath01 --device=/dev/sda3 --rule=failover      Partition is created ok but I don't have /dev/mapper/mpath01 file   multipath -l also shows nothing (service is running)


Trying customize Fedora rescue image - how do I go about this?

Most of what I've found on this involves changing install discs - which I don't really need. I just want to install a handful of extra packages and maybe some helpful scripts onto the Fedora rescue image and burn it to a disc for me and my boss to use when we image or tinker with computers (our imaging process is over NFS). Is there a good straightforward process to this or am I looking at rolling my own whole setup? Thanks for any input!


Script SFTP with password - HP-UX

I would like create a script in HP-UX to send in sftp with password. I have this command               sftp -o PasswordAuthentication=      but if I answer yes or no after, I have this issue "Host key verification failed"


Add GUI to Oracle Linux 6.4

I've installed Oracle Linux 6.4 on VirtualBox VM. As I understand, because of the fact that this is the server version, no GUI is installed by default. Can you guide me how to install/enable it? I believe that my Oracle Linux installation ISO file contains required packages but don't know how to mount it in Linux and reconfigure yum to use this local source instead of internet repository.


/usr/bin/host not picking up changes to /etc/hosts even after reboot

I have a Ubuntu Server 12.04 (`amd64`) machine on which, when I change `/etc/hosts`, the changes aren't picked up, even after a reboot. I am using `/usr/bin/host` to test, but none of the other programs seems to pick it up either. This is a server and `nscd` and `dnsmasq` aren't installed. Also, the file `/etc/nsswitch.conf` contains the line:               hosts:          files dns      so that I would expect it to work. I also checked that the `mtime` of the file changes with editing and tried running `service networking restart` (against all odds) and also `resolvconf -u`. All commands where run as `root` where needed. The machine has network configured manually in `/etc/network/interfaces` and not via Network Manager (it isn't installed either). Basically what I want to achieve is that the IP for a few hosts can be manipulated. The reason being that inside our network I get an IP to which I have no route, but I can use the external IP for that service via HTTPS. What am I missing? **Note:** no DNS server is locally running and the `nameserver` lines in `/etc/resolv.conf` (and the respective lines in `interfaces`) point to the DNS server that gives me the wrong IP. **Also note:** I've searched on the web and read through the "similar questions", but my case doesn't seem to be covered. `/etc/host.conf` is:               # The "order" line is only used by old versions of the C library.     order hosts,bind     multi on


What is the easiest way for me to take a video of what I'm doing on a Linux desktop?

Sort of like the Windows counterpart of CamStudio.


Book on how Linux works from an administrator's point of view?

I did find this book, but I was wondering whether there's a newer book on the market, because this one was released in 2004. I'm sure a lot has changed in the past 7 years? I need a book that helps me understand linux, instead of just giving me console recipes to reach certain goals. I need an overview picture of all its important components and how they work together, without going too much into kernel internals. Any help would be appreciated on finding an appropriate book for an administrator who is interested in this wonderful OS called Linux. I'm not a newbie to Linux, I just want to get the bigger picture, without turning myself into a kernel hacker. I already know what the Linux kernel is and does, I just want to know how it is leveraged in the larger scheme of things, and how everything that sits on top of it is organized, and the reason why certain things are organized the way they are.


Net-SNMP Application

I don't know if this is the right place to ask this question, but, does anyone knows about Net-SNMP. Is it possible to not truncate the log file whenever snmptrapd is restarted? The logs are being rotated by logrotate. But whenever I restart the snmp listener using this command:               /etc/init.d/snmptrapd restart      Or using this:               /etc/init.d/snmptrapd start      The log file for snmptrapd is being restarted to 0KB (restarted), previous logs are being deleted. We don't want that to happen.


How to install LuaJIT on FreeBSD without using Gmake?

Has anyone been able to install LuaJIT v2 on FreeBSD AMD64(x64) without using Gmake (just freebsd-make)? If so how? When I attempt to use freebsd-make, LuaJIT doesn't build.


Disable scroll lock

We have a shell/tty based application that has ~1,000 users. It is running in an environment where X Server is not available. If a user accidently turns on the `Scroll Lock`, it makes it seem as if the application is frozen because it quits responding to keyboard input. Is there a way to disable the `Scroll Lock` or remap it to something less intrusive for this use-case?


How to avoid a useless use of cat when parsing a file?

I have a file containing a list of directories. For instance               /foo/bar/dir1     /foo/bar/dir2     /foo/bar/dir3      I want to create all these directories. Here's what I did:               for dir in $(cat myfile); do mkdir $dir; done      What would be the correct way of doing this while avoiding the "useless use of cat"? Ideally, answers would focus on Ksh88, but I'm also interested in other shells


iptables rule adviser script

There is a server without any iptables defense: `ACCEPT all..` There could be custom applications on this server. If we should need to harden this server (so deny all, and only let what is needed by the applications) with strict iptables rules, we have to find out by hand that which app uses which `dst/src` `port/protocol` and then we have to write the iptables rules for them.. **The question** : are there any scripts that can help collecting these informations from a running machine? (from the logs?) - And automatically generating the iptables rules? Like there is the `audit2allow` on `SELinux`. Just for `iptables`! **The machine cannot have any outage!** Ex.: the "MAGIC" script should run a week/month on the machine, collecting informations, then, after a week/month, the script will be able to produce an iptables rule file that we can use. Many people could get in this situation (how to harden a server regarding iptables). And it would be great if there were a script/solution that can do this :\


ls -ld list files inside a folder which is having only execute permission

In Linux, I gave only `execute` permission to a directory named `test`. after switching to the directory `test`, when I run `ls -ld` it was showing some hidden files. Please explain this.


bash script calling itself with different arguments

I just can not get it right. Script takes two arguments, target and command. Valid targets are specified within an array. If target is 'all', script should iterate through all targets.               #!/bin/bash     # recur.sh          targets=('aaa' 'bbb' 'ccc' 'ddd')          if [ "$1" == "all" ] ; then         for i in $targets ; do             echo $2" --> "$i             ./$0 $i $2         done         exit 0     fi          echo "Target "$1" just received command '"$2"'"          exit 0      I expect the following output:               $ recur all boggle     boggle --> aaa     Target aaa just received command 'boggle'     boggle --> bbb     Target bbb just received command 'boggle'     boggle --> ccc     Target ccc just received command 'boggle'     boggle --> ddd     Target ddd just received command 'boggle'      But the script exits at the first iteration:               $ recur all boggle     boggle --> aaa     Target aaa just received command 'boggle'


Unix Command to return all files that end with single digit and TXT extension

Which command returns all files that end with a single digit and have the TXT extension ?


Building unprivileged (userns) LXC container from scratch, by migrating a privileged container to be unprivileged

How can I build a privileged LXC (1.0.3) container (that part I know) and then migrate it successfully to be run unprivileged? That is, I'd like to `debootstrap` it myself or adjust the `lxc-ubuntu` template (commonly under `/usr/share/lxc/templates`) in order for this to work. Here's why I am asking this question. If you look at the `lxc-ubuntu` template, you'll notice:               # Detect use under userns (unsupported)     for arg in "$@"; do         [ "$arg" = "--" ] && break         if [ "$arg" = "--mapped-uid" -o "$arg" = "--mapped-gid" ]; then             echo "This template can't be used for unprivileged containers." 1>&2             echo "You may want to try the \"download\" template instead." 1>&2             exit 1         fi     done      Following the use of `LXC_MAPPED_GID` and `LXC_MAPPED_UID` in the referenced `lxc-download` template, though, there seems to be nothing particularly special. In fact all it does is to adjust the file ownership (`chgrp` \+ `chown`). But it's possible that the extended attributes in the `download` template are fine-tuned already to accomplish whatever "magic" is needed. In the comments to this blog post by Stéphane Graber Stéphane tells a commenter that > There’s no easy way to do that unfortunately, you’d need to update your > container config to match that from an unprivileged container, move the > container’s directory over to the unprivileged user you want it to run as, > then use Serge’s uidshift program to change the ownership of all files. ... and to:   * have a look at https://jenkins.linuxcontainers.org/ for the packages built for the `download` template   * check out `uidmapshift` from here     * This program appears to roughly do `lxc-usernsexec -m b:0:1000:1 -m b:1:190000:1 -- /bin/chown 1:1 $file` as explained in `lxc-usernsexec(1)` But there are no further pointers. **So my question is: how can I take an ordinary (privileged) LXC container that I have built myself (having`root` and all) and migrate it to become an unprivileged container?** Even if you can't provide a script or so, it would be great to know which points to consider and how they affect the ability to run the unprivileged LXC container. I can come up with a script on my own and pledge to post it as an answer to this question if a solution can be found :) _Note:_ Although I am using Ubuntu 14.04, this is a _generic_ question.


How to try every bit of a Linux distro without installing it?

Using a live CD\USB to try a Linux distribution failed me to test aspects like graphics\wireless drivers. I remember when I tried an Ubuntu live CD it was loaded using a virtual machine so I couldn't test if my graphics drivers will be stable or not. So is there a way to fully test Linux distributions without having to install them which is a time consuming task and requires formatting the hard-disk with every installation ? Or at least test the graphics drivers availability ?


AWK-Find maximum value in a row & print with header

I need to read a file, find the maximum value in each row, and print the ID of the row, the column the maximum value came from (`sno#`), and the value from the associated `lc#` column. If the maximum value occurs more than once, I need to include all matches. For example: ### input.txt (tab-delimited)               Id  sno1  lc1  sno2  lc2    sno3  lc3  sno4 lc4     RM1  98   ss1   88   ms1    78    gs1   45  rs1     RM2  23   ss2   44   ms2    98    gs2   15  rs2     RM3  45   ss3   100  ms3    33    gs3   10  rs3     RM4  45   ss4   45   ms4    12    gs4   11  rs4      ### output.txt               RM1 ss1 sno1     RM2 gs2 sno3     RM3 ms3 sno2     RM4 ss4,ms4 sno1,sno2


User preferences not saved in Nemo file browser in Linux Mint 14 Cinnamon edition

I started using Linux Mint 14 (Nadia) recently, and kind of like it better for the Gnome experience its gives using Cinnamon DE. My question is, the file browser (NEMO 1.1.1) fails the save the defaults - the way I want it to display the folders and stuff. For example, I would like to have the folders listed in the 'List' form instead of the icon format, and would also like to have the "Location Entry" as default, instead of the bread crumbs model address bar in the file browser. I tried updating the preferences using the Edit > Preferences tool, however the updates are not stored, or getting reflected. I tried restarting Cinnamon, no effect. Also, I see that there is a toggle button to toggle between the bread crumbs mode and full address typing mode for the address bar, however I couldn't find a place which lets me select which one I need by default. Please suggest where I need to edit so that these settings can be saved permanently.


-bash: android: command not found

I'm on a Mac running Mavericks trying to learn how to develop Android apps (in the process I'm learning bash too). To run on the emulator they suggest the command `android avd`. I always get the error in the title of this post. I've searched all over and the issue seems to lie with changing the PATH. I've amended .bash_profile as such: `export PATH=/usr/local/bin:$PATH export PATH=/usr/local/bin:$PATH export PATH=/development/dev_android/sdk/tools:$PATH` but it's still not working. Any thoughts?


Modifying menu color of a gtk 3.0 theme

I'm trying to integrate a GTK3.0 theme with xfwm4 theme, ![enter image description here](http://i.stack.imgur.com/83MQf.png) Now I need to change the menu background color, so I get the color value with `gcolor` and tried to `grep` for that value, nothing found under the `gtk-3.0` folder. What's the right way of doing it? **EDIT** Faience GTK3.0 theme ZukiMac xfwm4 theme


Permissions on `/`

What should the permissions be for `/`? I ask because I completely removed all files from my drive and reinstalled the OS, but I still get "permission denied" errors for `/bin/zsh` when I try to log in as a non-root user. The only thing that is the same is the root of the drive. If that's the issue, I would like to not have to format and reinstall again to fix it. (any suggestions for that problem would be appreciated too.)


Kernel can not boot after upgrade on Fedora OS 15

I am using Fedora 15, and want to upgrade to version 16. I followed the official link Upgrading Fedora using yum - FedoraProject to upgrade my OS by the following command:               yum update kernel* --releasever=16     yum groupupdate Base  --releasever=16     reboot      After reboot, the OS does not start. It just prints the following message on screen:               could not start boot splash: No such file or directory      and nothing else. I have installed a lot of software on my previous OS, and I don't want to format my system partition. How to bring Fedora back to life without reinstalling the OS? Reinstall the OS would mean that I have to install a lot of software and do much configuration. It's a waste of time.


dump out some tables of the database

I am using **MySQL** v5.1 on **Ubuntu** machine. I have a database named `db_test` which contain tables like `cars`, `customers`, `departments`, `prices` , and so on. I know I can use the following commands to **dump out** the `db_test` database and **dump** the database **back** into a new database in following way:               mysqldump -u username -p -v db_test > db_test.sql     mysqladmin -u username -p create new_database     mysql -u username -p new_database < db_test.sql      But for my `new_database` , I **only needs some tables from** `db_test` database, **not all the tables**. So, How can I dump out some tables from `db_test` database and dump these tables back to my `new_database` ?


How to stop bash replacing commands in history with asterisks ? (‘*’)

I have some commands replaced with `*` in the bash history, e.g.               1094  apt-get update     1095*      1096  dpkg -i /var/cache/apt/archives/libssl1.0.0_1.0.0h-1_amd64.deb      How to prevent this?


Reporting Network and Vital Statistics and writing to db and image

I am looking for a versatile tool that can write either to a MySQL db, or possibly simply even just write some image charts (that i can display on a PHP dashboard) to monitor my network health. Is the best approach to run some type of daemon on my Debian box and somehow capture data from remote hosts via SSH? Also any CPU and process info would be useful in a tool like this. I've seen it done on routers' web interfaces, and I would like to be able to capture this data.


Why using rpm if there's yum?

As we know yum is a package management system which was built on top of rpm. It's also a command line utility which is a(rudely speaking) broader version of rpm, it resolves many problems(the main is obviously dependencies) which rpm doesn't care of. Is there any particular case when using rpm command would be more appropriate than yum?


mounting/converting v2i image in linux

Is it possible to mount a `v2i` image in linux?   Is there any `mount.v2i` program?   Or is there any convertion tool to convert `v2i` image to something else like `iso` ?   How can i Mount/Convert a `v2i` image? Thanks


How to run programs with arguments like 'arg=val' (e.g. dd) in rc shell (Linux version ported from Plan9 OS)?

I'm trying to use rc shell (Linux port from Plan9 OS) and get 'syntax error' messages when using programs with arguments like **arg=val**.               ; dd if=/dev/zero of=/dev/null     syntax error     ; ls --color=auto     syntax error      My guess is that rc shell sees **=** sign and treats the statement as variable assignment, not a program run. May be there's no dd program or other programs using this type of arguments in Plan9. But how can I use it in Linux where they are widely used? I tried escaping **=** like `dd if\=... of\=`, it didn't help. I tried quoting arguments like `dd 'if=/dev/zero' 'of=/dev/null' 'bs=1M' 'count=1'` and it worked. But it's not very comfortable. Is there any other more handy way? I'm using rc shell from Ubuntu 11.10 repository: package version 1.7.1-3ubuntu1.


Can't access Apache log folder

I want to see apache log file. This is what I tried: I granted most all permissions to **apache2** folder.               hieund@hieund:/var/log$ sudo chmod a+rw apache2/*      But I can't cd to it. So I add my user to group "root", "adm"               hieund@hieund:/var/log$ groups hieund     hieund : hieund root adm sudo www-data      But I still can't... It shows:               hieund@hieund:/var/log$ cd apache2/     bash: cd: apache2/: Permission denied     drwxrwxrw- 2 root              adm     4096 2011-11-27 11:12 apache2      I'm so confused about it. How to see log files?


Parse and remove a series of html files

I'd like to remove a series of elements like:               div-id="st-head" class="noprint"      from a html file.


Binding Shift-Enter to insert a newline without evaluating the current expression

I try to bind `Shift-Enter` to insert a newline without evaluating the current expression in the terminal and in repl modes. Reading through the ArchWiki, I tried setting this in my `~/.Xmodmap` file and reloading `~/.Xmodmap` with `xmodmap ~/.Xmodmap`. This however, does not work. Here is my detailed setup: content of:                   ~/.Xmodmap:         keysym Return = Return Linefeed      `~/.Xmodmap` is automatically resourced when logging in by setting:                   if [ -s ~/.Xmodmap ]; then             xmodmap ~/.Xmodmap              fi      in my `~/.xinitrc`. _Additional relevant info:_ (1) I set vi editing mode on in my `~/.bashrc` and my `~/.inputrc`. However, results did not differ when taking these options out. (2) Using `keysym Return = Return Linefeed` was suggested here.* Other methods did not work either. (3) My `$TERM` is set to `xterm-256color`. Thanks for any help! * * * *Update: The solution suggested on this page (if still to be found) cannot work in the specific case discussed there as the programming language is using its own repl implementation. So this does not have any bearing on the case at hand.


Apache2 userdir enabled, but still have no access

I am trying to set up an apache server on my Kubuntu 13.04 laptop. I have installed the apache2 package and `sudo a2enmod userdir; sudo service apache2 restart`, but still when I visit `http://localhost/~user`, it says something like this:               Forbidden          You don't have permission to access /~user on this server.          Apache/2.2.22 (Ubuntu) Server at localhost Port 80      Result of `tail /var/log/apache2/access.log`               127.0.0.1 - - [02/Aug/2013:16:22:01 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:16:22:02 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:17:35:30 +0200] "GET /~kaiyin HTTP/1.1" 403 501 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:17:35:30 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:17:35:30 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:17:36:26 +0200] "GET /favicon.ico HTTP/1.1" 404 499 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:17:36:26 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:21:05:17 +0200] "GET /~kaiyin HTTP/1.1" 403 501 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:21:05:17 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"     127.0.0.1 - - [02/Aug/2013:21:05:17 +0200] "GET /favicon.ico HTTP/1.1" 404 498 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.71 Safari/537.36"      Result of `tail /var/log/apache2/error.log`               [Fri Aug 02 21:05:17 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:05:17 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:06:54 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:06:54 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:06:59 2013] [error] [client 127.0.0.1] (13)Permission denied: access to /~kaiyin denied     [Fri Aug 02 21:06:59 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:06:59 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:07:17 2013] [error] [client 127.0.0.1] (13)Permission denied: access to /~kaiyin denied     [Fri Aug 02 21:07:17 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico     [Fri Aug 02 21:07:17 2013] [error] [client 127.0.0.1] File does not exist: /var/www/favicon.ico


can't uninstall netbeans in ubuntu

I am using netbeans8.0 new version, I want to uninstall lower version netbeans7.4 I tried using the following command in my `terminal`: > root@selvaksa-OEM:/usr/local/netbeans-7.4# sh uninstall.sh while executing this I get the following error:               Specified target component -nb-base/7.4.0.0.201310111528      was not found in the registry. the Installer      can continue as if the target component was not specified.     Click yes to continue, no to exit      if I click `yes`, it is asking to `uninstall` and then click `uninstall` to continue it is showing click `finish` to finish the IDE setup. > netbeans7.4 IDE


export PATH only once per login in zsh

I need to alter my `PATH` variable so I put `export PATH=$PATH:somedir` in my `$HOME/.profile` which is sourced by my `$HOME/.zshrc`. This works, yet whenever I open a new terminal (`urxvt` in `X11`), `.zshrc` and thus `.profile` is read, adding the `:somedir` to the `PATH` again. In my day to day computer use, the terminal windows come and go a lot, so after three hours of usage the `PATH` variable contains hundreds of clones of the `:somedir` appendix. How do I fix this? Is there a config file which is read by `zsh` only on login?


Services in /etc/rc.local prevent the system from finishing to boot

I start some services such as Tomcat and MySQL from a shell script `/etc/rc.local`. There is a while loop to restart the services. This loop is continuously running and my system is not booting. How can I solve this?


Counting files on a remote server with ssh and an expect script

Below is my script to take count for files which are present in remote server. But it is not working. Please help me.               #!/usr/bin/expect          spawn ssh sduser@172.0.0.2     expect "123"     send "123"     interact     destPath='/archive/Input/ERICIN/AIR/EMG'     dayStamp=`(date --date='1 day ago' '+%Y%m%d')`     if [ -d $destPath ]     then          cd $destPath          `cat 'emg_audit_1_'$dayStamp.csv|grep 'ACTPSO_NE_'$dayStamp|wc -l > /home/stsuser/eastregioncount/NEremote$dayStamp.txt`     else             echo "ERROR: Path $destPath Does not Exists."     fi


Fully Disable PrntScr Key

I recently came across a Linux feature I have never seen before, where pressing the PrntScr button on the keyboard prints a physical piece of paper with the contents of my console. I really need to find out how to disable this. It is driving me crazy. I followed a guide on creating a custom keymap, and I tried remapping it to Escape and loading my custom keymap instead, but it didn't seem to work. By disabling, I mean I would preferably like the key to not send any input at all, and ideally I would like to allow CUPS to continue running. What exactly controls this behavior? And are there any specific man pages I can read about this? **EDIT:** A little bit of additional info I should have given: I launch Openbox after logging into a TTY rather than using a DM. I am looking for a solution that would disable printing even if I were on a TTY, since PrntScr prints from a TTY as well.


How do I configure my tty session such that a form feed `\f` character will clear the terminal?

I'm connecting to a USB-serial connection on /dev/ttyACM0. The code on the sender side is sending a `\f` character at regular intervals.                   print("----------------------------\n\r");         print("-- LED CONTROLLER 00.01   --\n\r");         print("-- (c) 2013 STACEY RIECK  --\n\r");         print("----------------------------\n\r");         print("\n\f");      However, when I run `cat /dev/ttyACM0` from console, the output scrolls down my screen instead of refreshing at the top. I've dug through the current `stty` settings (by typing `stty -F /dev/ttyACM0 -a`) which gives the following output:               speed 115200 baud; rows 0; columns 0; line = 0;     intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^A; eol = <undef>; eol2 = <undef>; swtch = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V;     flush = ^O; min = 1; time = 0;     -parenb -parodd cs8 hupcl -cstopb cread -clocal -crtscts     -ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr -icrnl -ixon -ixoff -iuclc -ixany -imaxbel -iutf8     -opost -olcuc -ocrnl -onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0     -isig -icanon -iexten -echo -echoe -echok -echonl -noflsh -xcase -tostop -echoprt -echoctl -echoke      Reading the `stty --help` page gives the form feed delay (`ff0`), but doesn't indicate how to change anything else. I also found this page which indicates that I can set the FormFeed character like so `FormFeed=014`, but that syntax didn't work for my stty version (`stty --version` gives `stty (GNU coreutils) 8.5`). Putty in Windows exhibits the correct behaviour, but I'm struggling to get this to work in Debian 6. Does anyone know how I can configure stty to interpret a form feed as a terminal clear?


Concatenate filename inside of CSV file for each line for multiple CSV files

I have lots of CSV files and I need the filename of each specific CSV file in every line of each file. Original file content of `abc123.csv`:               ColVal_1;ColVal_2;ColVal_3     ColVal_4;ColVal_5;ColVal_6      New file content:               ColVal_1;ColVal_3;ColVal_3;abc123.csv     ColVal_4;ColVal_5;ColVal_6;abc123.csv      All CSV files are in the same directory. I don't want to specify the name of each file.


Permissions under a 700 (rwx------) directory

If a directory `/foo/bar/baz` has 700 (`rwx------`) for its permissions, thereby making it inaccessible to all but its owner (and the superuser), does it matter what the "group" and "other" permissions are for the directories and files under `/foo/bar/baz`? * * * What motivated this question is that I noticed that the files               /root/.bashrc     /root/.profile      in a freshly-installed Debian system have 644 (`rw-r--r--`) as their permissions. I would have expected 600 (`rw-------`) instead. But then I realized that `/root` itself has permission 700. This made me wonder whether a 700 permission of a directory would render moot the g- and o- permissions of anything under it. (If the answer is "no", i.e., if the g- and o- permissions of the contents _still_ matter even when a component along the path has 700 permissions, then I'd like to know if there's any reason _not_ to change the permissions of the files above to 600.)


Display conky always only on LVDS screen

I use the following settings in my `.conkyrc` to display a top bar on my laptop screen (LVDS).               background yes     update_interval 60     total_run_times 0     # Show umlauts     override_utf8_locale yes          # Font settings     use_xft yes     xftfont Noto Sans:style=normal:size=10     xftalpha 1          # Run in own window     own_window yes     own_window_class conky     own_window_type desktop          # Semi-transparent background     # http://th0th.me/log/conky-and-semi-transparency/     own_window_transparent no     own_window_argb_visual yes     own_window_argb_value 140          # Don't show in window lists and on all desktops     own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager     own_window_colour bcbcbc     double_buffer yes     draw_shades no     draw_outline no     draw_borders no     draw_graph_borders no     default_color 000000     alignment tl     maximum_width 1265     minimum_size 1265     #gap_x 10     gap_y 3     no_buffers yes     uppercase no     cpu_avg_samples 2      It is displayed as follows at the top of my screen: ![enter image description here](http://i.stack.imgur.com/zp6Cl.png) Now when plugging in an external monitor, I want to restrict the conky bar always to just my internal LVDS screen instead of displaying it across both screens.   * Output of xrandr without an external monitor connected   * Output of xrandr with external connected and LVDS to the right   * Output of xrandr with external connected and LVDS to the left Is it possible to tell conky to always stay on LVDS?


Screencast on a virtual monitor

is it possible to create virtual monitor (virtual area) and cast it to LAN? I would like to have something like external monitor, like Miracast, but not mirror. I think it is possible to create virtual area, record it (and compress by h264 or vp8) and share it by e.g. DLNA. Like http://realmike.org/blog/2011/02/09/live-desktop-streaming-via-dlna-on- gnulinux/ but with virtual monitor.


Java plugin not working with FireFox 24.3.0 on Red Hat Enterprise Linux 5.10

In the about:plugin tab, there is not Java plugin. I have created the symbolic link as suggested. The output of the 'ls -al' command is:               lrwxrwxrwx 1 shehab shehab   58 Jun  4 11:21 libnpjp2.so ->     /export/tools/oracle/jdk1.7.0_60/jre/lib/amd64/libnpjp2.so      The permission of the libnpjp2.so file is `-rwxr-xr-x` When I run the Java verifier at www.java.com I am getting the following error. > We are unable to verify if Java is currently installed and enabled in your > browser. > > If you have installed Java and there is an error with the verification, > there could be a configuration issue (eg. browser, Java control panel, > security settings). Try restarting your browser before trying to verify the > installation again. The Java console is not also available in the FF Tools menu. In the `~/.mozilla/firefox/lcus6cpf.default/pluginreg.dat` file I see the following:               [INVALID]     /import/projects/FPGA_tools/tools/linux/sun/jdk1.7.0_60/jre/lib/amd6/libnpjp2.so:$     1399495476000:$      Any clues what is going on? My Linux admin can run FireFox with Java with his account.


How to replicate a currently installed Linux system as an installation CD?

I have an installation of **Ubuntu 13.04** which I have customized to be just the way I want it (default applications, user accounts, desktop environment settings, ...). Now, I want to be able to basically put this system on a CD and install it to other PCs, just like a regular Ubuntu installation but with all of my customizations intact. Such a CD should be independent of my currently installed system but it should still be the regular Ubuntu (use the Ubuntu repositories for software updates etc.). How can I create such a CD? Where would I begin? * * * ## Progress and updates I installed **remastersys** following the kosnick answer which worked good:   * the ISO file was created   * I burned the ISO file on a DVD   * I inserted the DVD to another computer and installed it The issues I have now are:   * Some configuration files are missing. For example: `.vimrc` is missing   * theme files are missing (the KDE theme was not installed, but Oxigen default KDE theme was installed) How can I include them into my backup ISO?


Clonezilla won't boot up

I'm new to Ubuntu, and trying to make a backup with Clonezilla, but I can get only to the Clonezilla menu and after that I get a blank screen. I tried different USBs, but with no result. I also tried different Clonezilla versions. I have Ubuntu 12.04 and Windows 7 installed. What can cause that problem?


PHP exec and amixer

I'm trying to make php lower the dB level of amixer using exec, but it seems like php isn't able to perform the task which requires sudo-access. What should be the best way to solve this? I tried: PHP (each line is a own attempt)               echo shell_exec("sudo -u MYUSERNAME sh /var/www/html/music/volume.sh");     echo exec("sudo -u MYUSERNAME sh /var/www/html/music/volume.sh");     echo exec("sudo -u MYUSERNAME /var/www/html/music/volume.sh");      VISUDO               # Members of the admin group may gain root privileges     %admin ALL=(ALL) ALL          # Allow members of group sudo to execute any command     %sudo   ALL=(ALL:ALL) ALL          # See sudoers(5) for more information on "#include" directives:          #includedir /etc/sudoers.d     www-data ALL=(MYUSERNAME) NOPASSWD: /var/www/html/music/volume.sh


rsyslog: execute script on matching log event

I have the following line in my `/etc/rsyslog.conf`               :programname, contains, "suhosin" /var/log/suhosin.log      which logs all php security related incidents to `/var/log/suhosin.log`. That is nice, but I would like rsyslog to execute my script `action.sh` instead of logging to file. How could I do that?


Notification message tray?

Cinnamon desktop environment has a rather nifty idea of a tray in the systray that holds all notification messages till their read and cleared, and then becomes empty. How can I have the same thing in fluxbox please? I think it needs to be done via a bash script but I haven't the faintest idea where to start! This would be used on a debian testing machine under fluxbox desktop environment, but would hopefully be usable under ones like razor-qt as well.


pam: action on (unsuccessful) login

I know how to execute an action on login, by adding a line to `/etc/profile`. But that only gets executed, if the login was successful. I would like to have action executed even when login fails. For example run a script `script.sh`. I suspect, this can be set up in `pam`, but I have no idea where to start.


odd output from df command on a SLES

I know I'm not very good at math...but check out this output:               SERVER:~ # df -h /ORACLE/LOGS/b     Filesystem              Size    Used    Avail   Use%    Mounted on     /dev/mapper/LOGSdatavg-LOGSb_lv 96G 82G 9.0G    91% /ORACLE/LOGS/b     SERVER:~ #      SERVER:~ # df -i /ORACLE/LOGS/b     Filesystem              Inodes      IUsed   IFree       IUse%   Mounted on     /dev/mapper/LOGSdatavg-LOGSb_lv 12746752    30  12746722    1%  /ORACLE/LOGS/b     SERVER:~ # mount | grep -i /ORACLE/LOGS/b     /dev/mapper/LOGSdatavg-LOGSb_lv on /ORACLE/LOGS/b type ext3 (rw)     /dev/mapper/LOGSdatavg-LOGSblog_lv on /ORACLE/LOGS/b/log type ext3 (rw)     SERVER:~ #      SERVER:~ # uname -a     Linux SERVER 2.6.16.60-0.91.1-smp #1 SMP Tue Oct 18 21:40:25 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux     SERVER:~ # cat /etc/SuSE-release      SUSE Linux Enterprise Server 10 (x86_64)     VERSION = 10     PATCHLEVEL = 4     SERVER:~ #       Does anybody know why is 82G+9G=96G? Because I think it's 91G.


Content of AUTHORS file

Pedantic question. GNU recommend make `AUTHORS` file for list of authors and contributos of a program. But how many "levels" of authors and contributors should contain the file? E.g. I write a program `foo`, that actively use some library. Should I include authors of the library in the `AUTHORS`? It seems to yes, because total code of `foo` contain code from library. But if yes, I should include also authors of all others libraries, including standard libraries of compiler, authors of the compiler and other tools for producing final executable code, authors of OS... When I should stop?


Is it possible to compress a very large file (~30 GB) using gzip? If so, what commands, switches, and options should I use? Or is there another program (preferably one commonly available on Ubuntu distributions) that I can use to compress/zip very large files? Do you have any experience with this?


urxvt: how to scroll terminal output / hide mouse pointer

Two things that I miss in `urxvt` from `xterm` are:   1. How do you scroll up and down with the keyboard? In `xterm` I used Shift + Page Up (or Down), but that doesn't work.   2. A cool `xterm` feature is that when you type, the mouser pointer gets invisible. Anyway to get that in `urxvt`?


What's the right way to reuse this one-liner?

I recently came up with the following one-liner:               for f in *.mp3; do sha1sum $f | sed -r 's/[a-z]//g' | cut -c1-2 | awk '{ print ($1 >= 255) ? $1 - $1 + (1/3)*$1 : $1 }' | xargs -i id3v2 -T {} $f; done      I needed it because I've got an MP3 player that does not have a shuffle function. It was the only way I could find (in about an hour of trying) to give a suitably random distribution to track names. (At first I used `jot`, but this program does not update its random seed often enough to produce anything like random results. By the way, if anyone can think of a good way of doing this that actually works, I'm interested to hear about it.) I tried storing it as an alias and got:               awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:           ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                   ^ syntax error     awk: cmd. line:1: { print ( >= 255) ?  -  + (1/3)* :  }     awk: cmd. line:1:                                  ^ syntax error      It just seems like there should be a suitably easy way of storing it in my `.bashrc`. I'm aware that I could write it to a file and `chmod +x` it inside my `$path` with a shebang, but I prefer to use my `.bashrc` for things wherever possible.


How to configure an OpenWrt 10.03 router to forward an IPv6 connection to the clients?

So I have a TL-WR1043ND router with OpenWrt 10.03 on it. I have clients connected to it through the LAN ports. My ISP provides me a /64 IPv6 block, and I'm using PPPoE authentication. How can I configure this "average" set-up? (IPv6 day is coming! :) ) so that the connecting clients can use (visit sites over) IPv6 and IPv4 too? (no I don't want to use any tunneling)


History of Bash globbing

Is there a historical reason why Bash "globbing" and regular expressions are not identical? For example, I believe that in Bash `[1-2]*` matches anything that starts with a 1 or a 2 followed by anything else, while as a regular expression `[1-2]*` would match only a sequence of 1s and 2s. My Bash scripting and REGEX foo are both pretty weak and I regularly run into problems associated with these differences which made me curious was to why they are different.


Why Unix has ring like architecture , why not windows?

Unix has a architecture which looks like concentric rings, Windows has a rectangular architecture. Why is that so? Any specific reason for this kind of difference?