Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [ubuntu]

Ubuntu Linux is a Debian derivative that aims to bring Linux mainstream. Questions on this site should generally refer to Ubuntu Server. Note that http://askubuntu.com is specifically dedicated to Ubuntu questions.

22
votes
2answers
34k views

How can I block all but three ports in Ubuntu?

How can I block all ports except for 1962, 999, 12020? One port for SSH and two others for a kind of script. So, it's necessary to allow outgoing on these ports, right? My iptables: # Generated by ...
22
votes
4answers
37k views

How do I get apt-get to reinstall a package and run the set up scripts?

So I installed mailutils (apt-get install mailutils) and when I did a nice little setup screen popped up and started asking me questions. I guess I screwed up and cancelled out before I had all the ...
22
votes
3answers
42k views

Start Unix screen, Run command, Detach [duplicate]

How can screen be used to start a new session and run a command within that session without killing that session? screen -S myScreenName runSomething I tried the above command and it says [screen ...
22
votes
2answers
8k views

Prevent the possiblity of writing data to an unmounted mount point directory [duplicate]

I have an Ubuntu server where I'm automounting an external hard drive each boot. To do this, I've created an empty folder on the root partition, and the drive gets mounted "inside" this folder. ...
22
votes
4answers
262k views

What's the default username and password for an Ubuntu Live CD?

What's the username and password for an Ubuntu Live CD image? I ask because I've recently copied the contents of an Ubuntu based live ISO (easypeasy, the ldistro for nwtbooks) onto a hard disk drive, ...
22
votes
4answers
29k views

Ubuntu/Debian: Show list of available versions of a specific package

How can I list all available versions of specific package? I know with apt-get install myPackage=1.2.3 a specific version could be installed. And with apt-show-versions -a myPackage I would get ...
22
votes
8answers
37k views

How to remotely install Linux via SSH?

I need to remotely install Ubuntu Server 10.04 (x86) on a server currently running RHEL 3.4 (x86). I'll have to be very careful because no one can press the restart button for me if anything goes ...
22
votes
8answers
21k views

Can cron write job output to a log *by default* (instead of mail)?

We all know the right way to handle output from cron jobs is to redirect it to a file: 0 * * * * /bin/date >> /var/log/date.log 2>&1 However, sometimes admins are lazy, forgetful, or ...
21
votes
8answers
30k views

Need to fix file permissions in a user's home directory

Does anyone have a tool or script that will recursively correct the file permissions on a directory? On an Ubuntu Linux machine, a bunch of files were copied to a USB disk with full 777 permissions (...
21
votes
4answers
55k views

Why does the host command not resolve entries in /etc/hosts?

I have the following /etc/hosts file on a ubuntu 12.04 machine 127.0.0.1 localhost 10.248.27.66 ec2-50-112-220-110.us-west-2.compute.amazonaws.com puppetmaster # The following lines are desirable ...
21
votes
4answers
20k views

Explain in Plain English about Entropy Available

If I run this command in Ubuntu sudo cat /proc/sys/kernel/random/entropy_avail it returns a number that indicates how much "entropy" is available to the kernel, but that's about all I know. What ...
21
votes
4answers
12k views

Disable prompts while installing a Debian package

How can i disable totally the prompts that appear while installing a Debian package, i've used all the options that i've found but there are some packages that are still prompting. I'm using this ...
21
votes
1answer
46k views

Unable to execute gcc: No such file or directory

I am running Ubuntu LTS and I'm getting errors when trying to do some of my pip install stuff, like scrapy for example. This is the error I get: Unable to execute gcc: No such file or directory Error:...
21
votes
2answers
45k views

How to remove/backup script from /etc/init.d/?

I've been working with linux for a while but in a rather simple manner. I understand that scripts in init.d are executed when the os starts but how exactly does it works? What if I want to keep a ...
21
votes
2answers
28k views

Nginx Config: Front-End Reverse Proxy to Another Port

I have a small web server that serves requests on port 5010 rather than 80. I would like to use nginx as a front end proxy to receive requests on port 80 and then let those requests be handle by port ...
21
votes
1answer
13k views

How can I get Jenkins to stop listening for remote connections?

I have Jenkins sitting behind Nginx, with Nginx taking care of authentication, but Jenkins is still listening on port 8080 externally, so by accessing the box on port 8080 people can bypass Nginx. ...
20
votes
5answers
21k views

How do I turn off the beep in the terminal in Linux? [closed]

I've recently started using a new desktop PC with Ubuntu Linux installed. However the terminal beeps annoyingly. i.e. If I'm at the start of the line and I press Backspace, it'll beep to tell me that ...
20
votes
5answers
44k views

How do I get rsyslogd to log a server's FQDN instead of it's short hostname?

I'm trying to implement a simple centralized syslog server using stock rsyslogd (4.2.0-2ubuntu8.1) on Ubuntu 10.04 LTS. At this point I have all my client nodes sending logs to the central server, but ...
20
votes
3answers
20k views

UFW Firewall Rules ordering?

I have the following rules on our server within UFW: To Action From -- ------ ---- 22 ALLOW 217.22.12.111 22 ...
20
votes
4answers
13k views

What is NTP dispersion and how do I control it?

We roll out Ubuntu 14.04 servers on isolated networks, running ntpd 4.2.6p5, configured to use multiple NTP servers as provided by customers (no access to pool.ntp.org). Our dumb terminal client ...
20
votes
4answers
18k views

How to get HTTP preseed to work correctly on Ubuntu 10.04 LTS (Lucid)?

Installation media: ubuntu-10.04-desktop-i386.iso I tried a lot of different boot parameters, but either the installer ignored the preseed configuration, or it boot itself directly as LiveCD. An ...
20
votes
3answers
12k views

nginx logging to access.log.1 instead of access.log, logrotate failing?

I have an nginx instance that is set to log access to /var/log/nginx/access.log and errors to /var/log/nginx/errors.log, but as soon as logrotate runs each week, the file gets moves to *.log.1 and the ...
20
votes
4answers
53k views

Linux e1000e (Intel networking driver) problems galore, where do I start?

I'm currently having a major problem with e1000e (not working at all) in Ubuntu Maverick (1.0.2-k4), after resume I'm getting a lot of stuff in dmesg: [ 9085.820197] e1000e 0000:02:00.0: PCI INT A ...
20
votes
2answers
26k views

Installing imagick PHP extension on Ubuntu

I'm trying to install the imagick pecl extension on my Ubuntu server and am getting the below error. I've installed the ImageMagick rpm using aptitude already and the pecl extension is version 2.3.0. ...
20
votes
4answers
16k views

IBus >= 1.5.11 on Ubuntu

I'm running Ubuntu 15.04. I have the newest version of IBus installed, so does the command show: apt-get changelog ibus But the software I use (PHPStorm 10) gives a warning that IBus with version at ...
20
votes
7answers
120k views

Why is ntpd not updating the time on my server?

I have ntpd running on my server. It's all the default settings, except I commented out its ability to be a server to other machines: # restrict -4 default kod notrap nomodify nopeer noquery ...
20
votes
4answers
26k views

How to tell which Ubuntu package a tool is in

As a concrete example I want to be able to take a particular tool that isn't installed (say nslookup) and be able to tell which package I need to install when the following fails: apt-get install ...
20
votes
6answers
11k views

Verify TRIM support with BtrFS on SSD

We are looking into using BtrFS on an array of SSD disks and I have been asked to verify that BtrFS does in fact perform TRIM operations upon deleting a file. So far I have been unable to verify that ...
20
votes
4answers
17k views

“A new version of /boot/grub/menu.lst is available” when upgrading Ubuntu on an AWS server

I just tried to do a sudo do_release_upgrade on an AWS EC2 Ubuntu 13.10 server to upgrade to 14.04. All was going well until I got the following message: A new version of /boot/grub/menu.lst is ...
20
votes
2answers
124k views

Enabling mod_headers on apache2

I'm trying to enable the module "headers" into my apache2 installation on ubuntu 10.04 system, here's some info: Server version: Apache/2.2.14 (Ubuntu) when I run the command: a2enmod headers I ...
19
votes
3answers
118k views

How do I cleanly remove apache2 server on ubuntu server and then reinstall?

I am having some wierd issues with Apache2 server on my ubuntu server. I believe some configuration files may have been tampered with. What is the easiest way to remove apache2 completely from my ...
19
votes
3answers
69k views

How to check cron logs in Ubuntu

I went to /var/log/cron but this file is empty. How to check if crontab is enabled or is running properly or not in ubuntu thanks
19
votes
8answers
6k views

ack-grep to ack in ubuntu

I was just wondering, i recently installed ack (ack-grep in ubuntu), and i can't figure out how to just type in ack to get ack-grep (for some reason ack is taken up by a kanji translator thing). Is ...
19
votes
4answers
2k views

Is there a downside to installing VNC?

We have an Intel NUC in my university's language department that will soon host a web application used by faculty and students in the department. The NUC runs Ubuntu (14.10). I'm comfortable with the ...
19
votes
3answers
39k views

How do I clear the “s” permission on a directory in Linux?

I have a directory that is showing up with the permission mask drwsrwsr-x. When I try to reset the permissions to 755 the S still remains. What is the "s" and why cant I change the permissions ...
19
votes
3answers
18k views

Trying to get SSH with public key (no password) + google authenticator working on Ubuntu 14.04.1

I'm using Ubuntu 14.04.1 (with OpenSSH 6.6 and libpam-google-authenticator 20130529-2). I'm trying to set up SSH logins where the public key authenticates (without a password) and a user is prompted ...
19
votes
3answers
39k views

How to make system wide alias for “ls -l”? [closed]

I would like to have alias ll="ls -l" to be system wide. How is that done on Ubuntu?
19
votes
3answers
14k views

Directory in /var/run gets deleted after hard reboot

I keep my sphinx pid in /var/run/sphinx/searchd.pid but every time I hard reboot the directory /var/run/sphinx disappears and sphinx fails to start. Is there a way to make that directory stick or ...
19
votes
2answers
11k views

How to get top command output to show rake arguments?

In the past, all of our servers have automatically shown command arguments passed to rake when we view them in top. For example: But on this particular server, we get this instead (picture is top ...
19
votes
1answer
12k views

Can I have two versions of the same package in an apt repository?

I'm running Ubuntu 10.04 across my entire environment. To make code deploys easier, we are implementing a private apt repository where we can deploy builds of our code. One of the requirements of ...
18
votes
2answers
57k views

How To Tune Apache on Ubuntu 14.04 Server

Currently on my Apache 2 (Apache 2.4.7 to be exact) on Ubuntu 14.04, I have this setting: /etc/apache2/mods-enabled/mpm_prefork.conf <IfModule mpm_prefork_module> StartServers ...
18
votes
9answers
13k views

How to setup simple firewall on Ubuntu?

Could somebody give some simple steps with configuration example how to setup simple firewall on Ubuntu (using console only)? Only ssh, http and https access should be allowed.
18
votes
3answers
18k views

How do I see the changelog for a debian/ubuntu deb package?

I'm running Ubuntu and I have a deb file installed. I've made deb packages before, so I know there is a debian changelog (debchange). Is there anyway to see the debian changelog for any package that I ...
18
votes
3answers
38k views

hosts file seems to be ignored

I have almost fresh Ubuntu desktop box. OS was installed two weeks ago and updated from karmic repositories. Last week I had no problems with DNS. But this week something had changed. I'm not sure ...
18
votes
4answers
19k views

How do you swap the caps lock to control in xfce?

I used to have the caps lock and control swapped in GNOME, but when I upgraded to Ubuntu 9.04 I also changed my desktop environment to Xfce. I have the following line in my xorg.conf: Option ...
18
votes
2answers
35k views

What is the difference between sudo -i and sudo su -

What is the difference between commands sudo -i and sudo su -? Are they the same?
18
votes
3answers
28k views

Set group_concat_max_len permanently (MySQL config)

I have MySQL installed on an Ubuntu machine. I added this line in /etc/mysql/my.cnf group_concat_max_len=15360 But there is no effect. Every time I restart mysql, the value is set to 1,024. I have ...
18
votes
5answers
21k views

Recover from shutdown during Ubuntu distribution upgrade

I have a computer which was unexpectedly shut down during a distribution upgrade (Ubuntu 8.10 -> 9.04). It now won't finish booting - various X errors, then it goes to the login screen but won't ...
18
votes
1answer
33k views
18
votes
1answer
10k views

Why isn't my upstart service listed in service --status-all

I created a bunch of upstart jobs for my services that I'm running on an Ubuntu 12.04. I can successfully start them and stop with with: service my_service start service my_service stop but they are ...