Hello Marconi

>>
>>I made the following script to unban someone:
>>
>>#!/bin/bash
>>
>>rcdenyhosts stop
>>cd /var/lib/denyhosts
>>sed -i "/$1/d" *
>>cd /etc
>>sed -i "/$1/d" hosts.deny
>>rcdenyhosts start
>
>
>
> For OS X, the data dir is /var/lib/denyhosts/data
> so I changed the script but get sed errors:
>
> sed: 1: "allowed-hosts": command a expects \ followed by text
> sed: 1: "hosts.deny": extra characters at the end of h command
>
>
> I have no prior experience with sed.
>
> Anyone able to help me out?
>
>

I have no prior experience with OSX, but maybe it has similar issues
like Windows and isn't able to replace a file while open. Maybe you
need first to make temporary copies and move the files at the end?

Greets
Marcel

------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Denyhosts-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/denyhosts-user

Reply via email to