• Register
1 vote
45 views

Problem :

Is there anything I can do to solve the following problem?
unable to connect to upstart: failed to connect to socket /com/ubuntu/upstart: connection refused
6.9k points

2 Answers

0 votes

Solution :

Your runit seems to be incompatible with systemd on ubuntu, that may be a surprise after reboot So runit may just fail saying it is not pid 1:

- runit: fatal: must be run as process no 1.

So the other way is to switch to upstart:

sudo aptitude install upstart-sysv
sudo update-initramfs -u
sudo reboot
If you follow above steps your issue will be resolved.
36.1k points
0 votes

Solution:

Ubuntu switched to systemd as its service framework begining in 15.04 for all flavors, along Desktop and Server. The recommended exercise is to alter your upstart jobs to systemd jobs . You can further switch back to upstart in case you want, which is surely the quicker solve. I recommend you read the first some sections of the wiki article to weight the pros and cons.

Recommended Fix

Mention to the wiki article to transition your upstart scripts to systemd.

Quick Solve (for 15.04 only)

To abidingly switch back to upstart just run:

sudo apt-get install upstart-sysv
sudo update-initramfs -u
sudo reboot

I traced the issue for fail2ban was an error in the configuration file: /etc/fail2ban/jail.local

In the pam section, the port variable is listed twice

[pam-generic]

...

port     = all
banaction = iptables-allports
port     = anyport

In fact though this section is disabled (enabled = false) in my configuration, this reasons an error. I easily commented out this second definition

# port     = anyport

I constructed this by running fail2ban manually:

sudo fail2ban-client start

Vivid now conducts systemd instead of upstart.

You can attempt: "sudo systemctl start " instead.

Introduction

This document compares Upstart and systemd for supporting in the transition to the latter.

Support status

First, it is significant to note that systemd is just fully supported in Ubuntu 15.04 and later releases. While systemd is available in previously releases through the Ubuntu repositories, there is a deemphasis of support for these releases as noted here. Therefore, it is advised to employ the default upstart on prior releases.

System Init Daemon

This has altered as part of the Ubuntu 15.04 devel cycle.

Ubuntu 15.04 (employing Systemd by default):

Systemd runs with PID 1 as /sbin/init.

Upstart runs with PID 1 as /sbin/upstart. 

Previous versions (employing Upstart by default):

Upstart runs with PID 1 as /sbin/init.

Systemd runs with PID 1 as /lib/systemd/systemd. 

Switching init systems

In case you are running Ubuntu vivid (15.04), you can simply switch between upstart and systemd at will because both packages are installed at current. As of March 9 2015, vivid was altered to exercise systemd by default, prior that upstart was the default.

Switch to upstart for a single boot

In grub, select "Advanced options for Ubuntu", where you will trace an "Ubuntu, with Linux ... (upstart)" entry. This will boot with init=/sbin/upstart.

In case you have upstart-sysv installed and thus boot with upstart by default, there will be an "Ubuntu, with Linux ... (systemd)" entry, which will boot with init=/lib/systemd/systemd.

Permanent switch back to upstart

Install the upstart-sysv package, which will remove ubuntu-standard and systemd-sysv (however must not remove anything else -- in case it does), and run sudo update-initramfs -u. Afterwards, grub's "Advanced options" menu will have a similar "Ubuntu, with Linux .(systemd)" entry where you can do an one-time boot with systemd.

In case you want to switch back to systemd, install the systemd-sysv and ubuntu-standard packages.

Presently you can switch to upstart, impart the developers of the package in question of the require to support systemd.

17.7k points
edited by

Related questions

0 votes
1 answer 43 views
43 views
Problem : My problem kicked off when I was unable to log in as the root any more on the mysql install. I was trying to run mysql without the passwords turned on however when I ran my below command : # mysqld_safe --skip-grant-tables & I never got my prompt back. ... socket '/var/run/mysqld/mysqld.sock' (2)' Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
asked Jan 4 alecxe 7.5k points
0 votes
1 answer 34 views
34 views
Problem : My problem started with me when I was unable to log in as root any more on the mysql install. I was trying to run mysql without passwords turned on... but whenever I ran the below command # mysqld_safe --skip-grant-tables & I would never get my prompt back ... socket '/var/run/mysqld/mysqld.sock' (2)' Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
asked Dec 27, 2019 alecxe 7.5k points
0 votes
1 answer 1.4K views
1.4K views
Problem : I am trying to run startx via PuTTY and Xming but it gives following error: putty x11 proxy: unable to connect to forwarded x server: network error: connection refused
asked Nov 18, 2019 peterlaw 6.9k points
0 votes
1 answer 602 views
602 views
Problem : I am very new to Curl. I have recently started learning Curl. Whenever I try to connect to the Elasticsearch using below command curl http://localhost:9200 it is working properly. But when I try to run the following command curl http://IpAddress: ... showing me below error “Curl: (7) failed to connect to localhost port 9200: connection refused” How can I resolve above error?
asked Feb 20 mphil 2.3k points
0 votes
2 answers 99 views
99 views
Problem : I am often facing the below error when I want to Debug from my Eclipse IDE. Message: “Failed to connect to remote VM. Connection Refused” How can I fix this error?
asked Jan 8 alecxe 7.5k points