LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-02-2007, 01:32 PM   #1
kristof_v
Member
 
Registered: Feb 2006
Location: Belgium
Distribution: Debian
Posts: 84

Rep: Reputation: 15
DenyHosts fails to start after installation of newer python


hi,

i had DenyHosts running smoothly on my Debian server.
Then i decided to install fail2ban to protect Apache.

apt-get install fail2ban installed a newer version of python (python2.4) whereis python2.3 was used bu DenyHosts.

now when i try to start DenyHosts it fails with the follwoing message:

fileserver:/etc/fail2ban# /etc/init.d/denyhosts start
starting DenyHosts: /usr/bin/env python /usr/bin/denyhosts.py --daemon --config=/usr/share/denyhosts/denyhosts.cfg
Traceback (most recent call last):
File "/usr/bin/denyhosts.py", line 5, in ?
import DenyHosts.python_version
ImportError: No module named DenyHosts.python_version


i would like to get DenyHosts running again

grtz
 
Old 01-03-2007, 02:39 AM   #2
kristof_v
Member
 
Registered: Feb 2006
Location: Belgium
Distribution: Debian
Posts: 84

Original Poster
Rep: Reputation: 15
solved:

Hi,

I'm trying to get DenyHosts 2.4 running on my system. I am running
Python2.4. I have configured everything correctly (I believe), however
when I try to load DenyHosts via daemon-control I receive a series of
trackback messages and then "DenyHosts exited abnormally".

> Whoops. My bad. I just released 2.4b which should fix this problem.

Regards,

Phil
 
Old 08-14-2007, 12:52 PM   #3
natv
Member
 
Registered: Mar 2006
Posts: 66

Rep: Reputation: 15
fix

HI,

I had the same problem and researched it and here is the fix, change this to what I changed:

Edit /usr/share/denyhosts/daemon-control

#PYTHON_BIN = "/usr/bin/env python"
PYTHON_BIN = "/usr/bin/env python2.4"


adding the 2.4 is what fixed it.

Hope this helps.
 
Old 08-06-2009, 06:24 AM   #4
cronky
LQ Newbie
 
Registered: Aug 2009
Location: UK
Distribution: Ubuntu
Posts: 1

Rep: Reputation: 0
Lightbulb Fix for Ubuntu is slightly different (different file)

Great thread - thanks guys. I sorted the problem on Ubuntu (scary that Denyhosts hasn't been running for sometime - it took someone almost DoS my box through SSH requests to realise - which is not good).

Although I found the file you need to change on Ubuntu is: /usr/share/denyhosts/daemon-control-dist rather than the one mentioned.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Installation Suse 10.0 on laptop fails with first start-up |piet> Linux - Newbie 3 08-22-2006 02:57 PM
Logwatch Filter for DenyHosts - Getting Error rustyz82 Linux - Software 1 08-07-2006 07:52 PM
linux suse 9.2 64 bit version installation, yast fails to start up azulpind4 SUSE / openSUSE 16 07-04-2005 01:53 PM
Upgrading Python to newer version dopper Linux - Software 3 02-19-2004 12:10 PM
python: import distutils fails on debian? jpbarto Linux - Software 0 01-18-2004 10:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:34 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration