2
votes
3answers
1k views

Match a single character in a string bash script

My issues is that I want to read a character from the stdin and compare it with a string value. If that character exists then I want to display a message. Eg, saving % into the variable $a: $ read a ...
1
vote
1answer
828 views

cannot start PostgreSQL on OpenBSD 5.4 through rc.d

I've installed the postgresql-server package on OpenBSD 5.4 amd64, and I try starting it through its rc.d script, however, it doesn't look like it's running after that. opti# /etc/rc.d/postgresql ...
1
vote
1answer
2k views

Reverse id command, I want the User/Group Name from the uid or gid

I know some uid and gids that I dont know who they belong to and they are not in /etc/passwd (could be LDAP or from another system). How do I get Id info from only uid or gid preferably without using ...
2
votes
1answer
7k views

Ubuntu: how do you swap eth0 and eth1? (Ubuntu 13.10 server in a VirtualBox VM)

I installed Ubuntu 13.10 server (64-bit) in a VirtualBox 4.3.6 VM (Windows host) with one NAT adapter assigned. The only non-default software selected during installation was OpenSSH. So far so ...
3
votes
2answers
3k views

How to Free Up Space in a Dynamically Growing qcow2 VM image?

This has happened to one of my VM's that's running CentOS under Proxmox. I copied about 40 GB of data into a VM. I then deleted that 40 GB data a day later. Now taking a backup of the same VM takes ...
1
vote
1answer
106 views

How to create a patch file for new source code [closed]

I am trying to do a mini code review for new source code that I have in a folder. The code is not in any kind of version control. Is it possible to create a patch file from this so I can post it for ...
0
votes
0answers
776 views

Postfix not responding to telnet

I am doing a Postfix installation on CentOS 6.5 I can't get # telnet localhost 25 to do more than this: Trying ::1... Connected to localhost. Escape character is '^]'. EHLO ^] telnet> quit ...
5
votes
3answers
50k views

How to repair a corrupted HFS+ partition from a damaged hard-disk?

I have a friend's Mac OS X disk that comes with an HFS+ partition. I am supposed to recover the personal data from this disk, and I'm not yet sure if the filesystem is corrupted or the disk is dying). ...
2
votes
0answers
35 views

Mount a workstation dir upon login to server over ssh

I'd like to have a local directory be mounted upon logging into a remote server via SSH. So if I were to ssh into foo.bar.com as user baz then there would be a directory mounted in /home/baz/roaming - ...
0
votes
2answers
8k views

What causes cron to continuously send mail and how can I disable it?

I have a problem on CentOS 6.3 system where the crond process tries to unsuccessfully send mail over and over (at least I think this is what its doing) until the OS eventually generates a "too many ...
4
votes
2answers
4k views

Escaping blackslash in sed

I am trying to write a sed command to replace a line in a file. The sed replace required the current working directory, which starts making the command a bit messy because of the characters that need ...
3
votes
1answer
379 views

How to hide files from Bash? [closed]

On the Git Bash shell on Windows, I'm stuck looking at crap left by Windows in my home directory: NTUSER.DAT NTUSER.DAT{016888bd-6c6f-11de-8d1d-001e0bcde3ec}.TM.blf ...
0
votes
1answer
2k views

Video4Linux installation [closed]

I 'm running Angstrom distribution (console only) on BeagleBoard-xM. Image was build on Narcissus, with Bootloader Files (x-load/u-boot/scripts) added. I want to connect a USB webcam (Logitech Pro ...
4
votes
1answer
91 views

Moving to Solaris (from Linux) [closed]

I got curious about why not so many people have Solaris in their desktops and laptops. I wonder whether it's a good idea at all, or something just for the absolute geek. Could I maybe give it a try ...
6
votes
4answers
45k views

Java “Could not reserve enough space for object heap” even though there is enough RAM

I am currently having some issues running Java. It won't start because of heap issues. But I have more than 9 GB Ram free (or even 16 GB if you assumed the cache would be empty). This is the error I ...
4
votes
1answer
322 views

How can I prefer one wifi network over another?

From my home I have access to my home wifi network as well as a public network that is deployed throughout the city. The public network has a lower signal strength and is unprotected. However, my ...
4
votes
1answer
726 views

Why do the data and code segments completely overlap in Linux?

Context: I'm reading "Understanding the Linux kernel, 3d ed", which uses the 2.6.11 kernel. Question: As I understand, the physical address is obtained by translating the linear address, which is ...
0
votes
1answer
426 views

Some garbage characters in Linux terminal

My embedded linux app sometimes outputs the text like this: root@variscite /mnt/nfs$ ./test GPIO_IMX6_C: i=1 cannot open GPIO device file /sys/class/gpio/gð½Å¢ ...
0
votes
0answers
25 views

How to restore desktop configs after an intallation

I have recently installed PgAdminIII and Geany via Ubuntu Software Center, but this changed my desktop configurations. It no longer looks like it did. I am using Pinguy OS 12.10 based on Ubuntu ...
1
vote
1answer
1k views

no irq handler vector

I'm a Linux newbie and I've just installed CentOS 6.4 on my desktop machine. Everytime I start my terminal I get these error messages and I can't figure out why. How can I trace the problem and fix ...
4
votes
1answer
3k views

command to reboot as non-root user

I am using LXDE on Debian. When logged in LXDE as user, I can click on the logout icon in the menu and choose one of the options: shutdown reboot logout suspend But when I type reboot or shutdown ...
11
votes
3answers
964 views

Is there a Linux deep diff tool that also compares file attributes?

Is there a Linux tool like diff that will recursively compare files and directories, but with the addition of also comparing: extended attributes, acl's, se contexts?
0
votes
4answers
20k views

I can't use the command ftp

When I try to install ftp: $ sudo yum install ftp Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile Setting up Install Process No package ftp available. Error: Nothing to do ...
2
votes
1answer
10k views

Fedora 19: can't disable the firewall

I've installed a server (WSO2 ESB) in my laptop. When I run it, going to the browser and typing the console address https://10.13.6.75:9443/carbon, it works normally, but if I try it on another ...
1
vote
1answer
2k views

Saving a kernel config file through menuconfig results with different options?

I'm experimenting with different kernel configuration files and wanted to keep a log on the ones I used. Here is the situation: There is configuration file called my_config which i want to use as ...
2
votes
2answers
36k views

Shell scripting: -z and -n options with if

I have a shell script where we have following lines if [ -z "$xyz" ] and if [ -n "$abc" ], but I am not sure what their purpose is. Can anyone please explain?
4
votes
1answer
513 views

Something like VMware “Changed Block Tracking” (CBT) in linux

I'm wondering if is there any possibility to track changed blocks in linux with an ext3/ext4 filesystem (or a specific one supporting it). I mean a feture like the Changed Block Tracking (CBT) ...
1
vote
0answers
1k views

OpenWRT configuration when router is in bridged mode

I am planning on putting my Zyxel ADSL modem in bridged mode and use an OpenWRT router instead as the exit point from my local network. So, what protocol must have the Wan interface if the router is ...
0
votes
1answer
52 views

IP Prefix - how do I declare this?

Hi I have an IP Prefix issue I would like to declare the following IP's as "safe" using ip prefix "methodology" ("?") The IP's first three parts of the IP have been doctored to protect the innocent, ...
1
vote
2answers
214 views

How to get the group that a user belongs to in SCO

I can see how to add a user, but is there a way to get information on a user, such as the group that it belongs to?
0
votes
4answers
159 views

Can I have the shell ignore the command line sometimes but not always?

For debugging purpose sometimes I access a remote Linux box via VNC. At that time someone else may be working on that same Linux box through VNC and it may happen that I do not have facility to chat ...
3
votes
1answer
492 views

Easiest method to create pdf from template using command line (without pdflatex)?

For ten years I have been generating billings for me and my wife in this way: Create TeX template with LyX or by hand Using in this source placeholder text Then: cat template | sed ...
3
votes
1answer
213 views

sshfs LocalForward without config file

I'm trying to add portforwarding to my sshfs-mount-scripts: sshfs tim@devserver1:/ /home/tim/mnt/devserver1/ -o SSHOPT=LocalForward 127.0.0.5:3306 127.0.0.1:3306 So far I've failed using the ...
2
votes
2answers
231 views

How does system know where the first logical disk starts?

I'm trying to understand the ms-dos partition table, and there's the following diagram: It comes from this site. Almost everything is pretty clear to me, but there's one thing I don't get. As you ...
4
votes
1answer
448 views

ARP request with wrong IP address

I have a strange problem with a Linux router. The setup is like this: host1 === Linux router === host2 a.b.c.d --- a.b.c.e/g.h.i.j --- g.i.h.k Every five minutes host1 tries to reach host2. ...
1
vote
1answer
46 views

Let the server own the file created by the client on a Samba share

I'm sharing a directory on my Mac using Samba. When the client (Raspebian) creates a file on the mounted share, the file is owned by the user on the client and the permissions are set to -rw-------. ...
2
votes
2answers
163 views

What was the old linux game for programmers, simulating a life on a grid of pixels? [closed]

I remember about 10 years ago in the official Linux repository there was a program, simulating a life of creatures on a grid of pixels (each occupying one pixel). The point of the "game" was in ...
15
votes
9answers
138k views

yum update fails: Error: Cannot retrieve repository metadata (repomd.xml) for repository …

I'm using CentOS 6.3. When I try to update my system with yum I have this message: yum update Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: mirrors.ircam.fr * ...
0
votes
3answers
2k views

SSH public key authentication works on LAN and not from WAN

I've setup my SSH server to use public key authentication. When I connect to my server on local network, it authenticates. But it doesn't when I connect over the internet. I don't think the problem ...
0
votes
2answers
2k views

Ssh 'access denied' from one host but not the other

Consider the following scenario: I have a Debian-ssh-server setup and exposed it to the internet for some time for testing. Also I have an account which is basically configured as root in the sudoers ...
2
votes
2answers
1k views

How do I get my laptop screen backlight brightness controls to work?

What do I need to do to get my laptop screen backlight brightness controls to work? I currently have Ubuntu 13.04 and a Dell Studio 1558. After reading these two links: ...
2
votes
1answer
326 views

Linux Equivalent of Windows Reparse Points?

I've recently become aware of a neat feature of Windows file systems called a reparse point. My understanding is that they are files whose contents when read are not the contents on the actual disk, ...
2
votes
1answer
345 views

Why it is necessary to update /etc/default/grub, and not just save it?

I understand that the grub file contains some instructions that are required before booting such as: booting in text or booting in Graphics mode. My question is why do I need update-grub? Why just ...
21
votes
4answers
3k views

Automatically detect when I typed “vi” but meant “cd”?

Title says it all. About 5 times a day, I type "vi" when I meant "cd", and end up opening a directory in vi. It's making me NUTS. It seems like there should be a way to detect when I type in "vi + ...
2
votes
2answers
654 views

Shell script to wait for a packet from a certain port

I want to start my minecraft server when someone tries to connect to it on port 25565. I have a plugin for the server which shuts it down after x amount of minutes without players online. With a shell ...
3
votes
1answer
354 views

Show in folder does not select file

In various applications when I do "show file in folder" it simply open the file-manager (nemo) but does not select the actual file. How can I make show in folder also select the file?
2
votes
1answer
4k views

“stdin: is not a tty” mails for running scripts as cron jobs

I have several shell scripts (bash) which are started by cron. Every time a script is executed I get an email saying "stdin: is not a tty". Can someone please tell me how to fix this? All scripts run ...
1
vote
1answer
921 views

How to escape spaces while using command's output in command line [duplicate]

I want to perform the following command in command line : $ md5sum $(find . -type f) But this would cause problems when it encounter files with spaces in filenames : md5sum: Kaufmann: No such ...
5
votes
1answer
720 views

Reset running process when certain ammount of memory is consumed

I'm running a Hydra on Rasppberry PI. There were some problems with the program, but aside from these, there is a hidden memory leak in the program. The source is pretty big and really can't find the ...
1
vote
2answers
2k views

Debian: How to resolve Xserver failure

I keep finding similar posts online but I can't really use the solutions in my case. in my /etc/bash.bashrc file, I have the following code placed at the very bottom: if [ -e /tmp/.X0-lock ]; then ...

15 30 50 per page