Hi My problem boils down to porting this xinetd file to launchd: # default: off # description: Bitlbee is an IRC gateway to other networks. service ircd { type = UNLISTED socket_type = stream protocol = tcp wait = no user = bitlbee group = nogroup server = /sw/sbin/bitlbee port = 6667 disable = no log_on_failure += USERID } So this is what I have come up with: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd "> <plist version="1.0"> <dict> <key>KeepAlive</key> <true/> <key>Label</key> <string>org.bitlbee.bitlbee</string> <key>OnDemand</key> <true/> <key>ProgramArguments</key> <array> <string>/sw/sbin/bitlbee</string> </array> <key>ServiceDescription</key> <string>bitlbee irc-im proxy</string> <key>Sockets</key> <dict> <key>Listener</key> <dict> <key>SockFamily</key> <string>IPv4</string> <key>SockProtocol</key> <string>TCP</string> <key>SockServiceName</key> <string>6667</string> <key>SockType</key> <string>stream</string> </dict> </dict> <key>inetdCompatibility</key> <dict> <key>Wait</key> <false/> </dict> <key>UserName</key> <string>bitlbee</string> </dict> </plist> And well it does not work. When I try to load (launchctl load thisfile.plist) I always get a "bind(): Operation not permitted" error and I can't connect to the server. And how would I restrict the service to localhost only? I guess I'm missing something. I'd just like to have bitlbee working in leopard. Would apreciate some help. Johannes
Are you making sure to run launchctl as root? Once you do, is the job already loaded? Check like so: sudo launchctl list | grep org.bitlbee.bitlbee Also, please remove the KeepAlive key/value pair. It is incompatible with the rest of the plist. I suppose we should add a sanity check for that... Oh well. Cheers, davez On Nov 1, 2007, at 3:44 PM, Johannes Kneer wrote:
Hi
My problem boils down to porting this xinetd file to launchd:
# default: off # description: Bitlbee is an IRC gateway to other networks. service ircd { type = UNLISTED socket_type = stream protocol = tcp wait = no user = bitlbee group = nogroup server = /sw/sbin/bitlbee port = 6667 disable = no log_on_failure += USERID }
So this is what I have come up with:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd "> <plist version="1.0"> <dict> <key>KeepAlive</key> <true/> <key>Label</key> <string>org.bitlbee.bitlbee</string> <key>OnDemand</key> <true/> <key>ProgramArguments</key> <array> <string>/sw/sbin/bitlbee</string> </array> <key>ServiceDescription</key> <string>bitlbee irc-im proxy</string> <key>Sockets</key> <dict> <key>Listener</key> <dict> <key>SockFamily</key> <string>IPv4</string> <key>SockProtocol</key> <string>TCP</string> <key>SockServiceName</key> <string>6667</string> <key>SockType</key> <string>stream</string> </dict> </dict> <key>inetdCompatibility</key> <dict> <key>Wait</key> <false/> </dict> <key>UserName</key> <string>bitlbee</string> </dict> </plist>
And well it does not work. When I try to load (launchctl load thisfile.plist) I always get a "bind(): Operation not permitted" error and I can't connect to the server. And how would I restrict the service to localhost only?
I guess I'm missing something. I'd just like to have bitlbee working in leopard. Would apreciate some help.
Johannes
_______________________________________________ launchd-dev mailing list launchd-dev@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo/launchd-dev
Hi
Are you making sure to run launchctl as root? Once you do, is the job already loaded? Check like so: sudo launchctl list | grep org.bitlbee.bitlbee
host:~ root# launchctl unload /Library/LaunchDaemons/ org.bitlbee.bitlbee.plist host:~ root# vim /Library/LaunchDaemons/org.bitlbee.bitlbee.plist *host:~ root# launchctl load /Library/LaunchDaemons/ org.bitlbee.bitlbee.plist bind(): Operation not permitted host:~ root# launchctl list | grep org.bitlbee.bitlbee - 0 org.bitlbee.bitlbee host:~ root# telnet 127.0.0.1 6667 Trying 127.0.0.1... host: connect to address 127.0.0.1: Connection refused host: Unable to connect to remote host host:~ root# (I like ssh root@localhost more than sudo :)
Also, please remove the KeepAlive key/value pair. It is incompatible with the rest of the plist. I suppose we should add a sanity check for that... Oh well.
The above took place with the removed KeepAlive key/value pair. And I guess a sanity check is a good idea... I'm wondering about the low traffic here on the list. Launchd is now a central column of the OS X experience - and no more developers have questions about it? cheers, Johannes
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd "> <plist version="1.0"> <dict> <key>Label</key> <string>org.bitlbee.bitlbee</string> <key>OnDemand</key> <true/> <key>ProgramArguments</key> <array> <string>/sw/sbin/bitlbee</string> </array> <key>ServiceDescription</key> <string>bitlbee irc-im proxy</string> <key>Sockets</key> <dict> <key>Listener</key> <dict> <key>SockFamily</key> <string>IPv4</string> <key>SockProtocol</key> <string>TCP</string> <key>SockServiceName</key> <string>6667</string> <key>SockType</key> <string>stream</string> </dict> </dict> <key>inetdCompatibility</key> <dict> <key>Wait</key> <false/> </dict> <key>UserName</key> <string>bitlbee</string> </dict> </plist>
On Nov 1, 2007, at 4:47 PM, Johannes Kneer wrote:
Hi
Are you making sure to run launchctl as root? Once you do, is the job already loaded? Check like so: sudo launchctl list | grep org.bitlbee.bitlbee
host:~ root# launchctl unload /Library/LaunchDaemons/ org.bitlbee.bitlbee.plist host:~ root# vim /Library/LaunchDaemons/org.bitlbee.bitlbee.plist *host:~ root# launchctl load /Library/LaunchDaemons/ org.bitlbee.bitlbee.plist bind(): Operation not permitted host:~ root# launchctl list | grep org.bitlbee.bitlbee - 0 org.bitlbee.bitlbee host:~ root# telnet 127.0.0.1 6667 Trying 127.0.0.1... host: connect to address 127.0.0.1: Connection refused host: Unable to connect to remote host host:~ root#
(I like ssh root@localhost more than sudo :)
Odd. What does the output of "lsof -P | grep 6667" say? Do you have any firewall magic installed or configured? Is a pre- existing copy of the daemon already running? The bind() error means this is more of a networking problem than a launchd problem...
Also, please remove the KeepAlive key/value pair. It is incompatible with the rest of the plist. I suppose we should add a sanity check for that... Oh well.
The above took place with the removed KeepAlive key/value pair. And I guess a sanity check is a good idea... I'm wondering about the low traffic here on the list. Launchd is now a central column of the OS X experience - and no more developers have questions about it?
I guess developers are either content, or not using it. :-P davez
On 02.11.2007, at 00:52, Dave Zarzycki wrote:
On Nov 1, 2007, at 4:47 PM, Johannes Kneer wrote:
Hi
Are you making sure to run launchctl as root? Once you do, is the job already loaded? Check like so: sudo launchctl list | grep org.bitlbee.bitlbee
host:~ root# launchctl unload /Library/LaunchDaemons/ org.bitlbee.bitlbee.plist host:~ root# vim /Library/LaunchDaemons/org.bitlbee.bitlbee.plist *host:~ root# launchctl load /Library/LaunchDaemons/ org.bitlbee.bitlbee.plist bind(): Operation not permitted host:~ root# launchctl list | grep org.bitlbee.bitlbee - 0 org.bitlbee.bitlbee host:~ root# telnet 127.0.0.1 6667 Trying 127.0.0.1... host: connect to address 127.0.0.1: Connection refused host: Unable to connect to remote host host:~ root#
(I like ssh root@localhost more than sudo :)
Odd.
What does the output of "lsof -P | grep 6667" say?
host:~ root# lsof -P | grep 6667 host:~ root# launchctl list | grep org.bitlbee.bitlbee - 0 org.bitlbee.bitlbee host:~ root# lsof -P | grep 6667 host:~ root#
Do you have any firewall magic installed or configured? Is a pre- existing copy of the daemon already running?
I have! The build in one was on "set access for specific services and applications". But that's all, no ipfw stuff. If I turn it of, or if I put bitlbee manually in the list of allowed apps I can connect to it. BUT why am I not asked whether or not to allow the connection in the GUI? This feels like a GUI bug to me. But it works now. Thank you.
The bind() error means this is more of a networking problem than a launchd problem...
Cheers, Johannes
Do you have any firewall magic installed or configured? Is a pre- existing copy of the daemon already running?
I have! The build in one was on "set access for specific services and applications". But that's all, no ipfw stuff. If I turn it of, or if I put bitlbee manually in the list of allowed apps I can connect to it. BUT why am I not asked whether or not to allow the connection in the GUI? This feels like a GUI bug to me.
But it works now. Thank you.
I'm still having this problem. I see where to set "Allow all incoming connection" and that also fixes it for me. However, if I specify the location of bitlbee and use "Set access for specific services and applications" I still get the "bind() operation not permitted" error. That was all in Preferences -> Security -> Firewall. Is there another place I should be looking? Thanks, Brian -- View this message in context: http://www.nabble.com/bitlbee---xinetd-to-launchd-tf4734511.html#a13661342 Sent from the Launchd mailing list archive at Nabble.com.
On Nov 8, 2007, at 8:17 PM, bpkroth wrote:
I'm still having this problem. I see where to set "Allow all incoming connection" and that also fixes it for me. However, if I specify the location of bitlbee and use "Set access for specific services and applications" I still get the "bind() operation not permitted" error. That was all in Preferences -> Security -> Firewall. Is there another place I should be looking?
I'm afraid you've moved out of the area of expertise on this launchd- dev list. Your question might be better asked on one of the more general Darwin lists (i.e. darwin-dev@lists.apple.com) where someone more familiar with the Leopard firewall may be lurking. - Kevin
Kevin Van Vechten-2 wrote:
On Nov 8, 2007, at 8:17 PM, bpkroth wrote:
I'm still having this problem. I see where to set "Allow all incoming connection" and that also fixes it for me. However, if I specify the location of bitlbee and use "Set access for specific services and applications" I still get the "bind() operation not permitted" error. That was all in Preferences -> Security -> Firewall. Is there another place I should be looking?
I'm afraid you've moved out of the area of expertise on this launchd- dev list. Your question might be better asked on one of the more general Darwin lists (i.e. darwin-dev@lists.apple.com) where someone more familiar with the Leopard firewall may be lurking.
- Kevin _______________________________________________ launchd-dev mailing list launchd-dev@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo/launchd-dev
Turns out a reboot fixed my problem. Thanks, Brian -- View this message in context: http://www.nabble.com/bitlbee---xinetd-to-launchd-tf4734511.html#a13679082 Sent from the Launchd mailing list archive at Nabble.com.
I guess developers are either content, or not using it. :-P
Well, in our case, our questions centered around the functioning of launchd in Leopard specifically, so this public list was not an appropriate place and we took them directly to Apple. Joseph Jacobs Motorola, Inc.
participants (5)
-
bpkroth
-
Dave Zarzycki
-
Jacobs Joseph-MRG836
-
Johannes Kneer
-
Kevin Van Vechten