Upgrading Transmission from 2.82 -> 2.84.2 causes Unable to save pidfile and Permission denied

Status
Not open for further replies.

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Hi all or Joshua :)

I just upgraded transmission from 2.82 to 2.84.2 from the GUI and the upgrade was successful except the configuration page was all corrupted.

I then deleted the plug-in and uploaded the package to the jail successfully however after the upload the plug-in did not start.

I get the following messages in the log file:

Nov 15 14:36:54 downloads transmission-daemon[66003]: Couldn't bind port 51413 on 0.0.0.0: Address already in use (Is another copy of Transmission already running?) (net.c:371)
Nov 15 14:36:54 downloads transmission-daemon[66003]: Couldn't bind port 51413 on ::: Address already in use (Is another copy of Transmission already running?) (net.c:371)
Nov 15 14:36:54 downloads transmission-daemon[66003]: UDP Couldn't bind IPv4 socket (tr-udp.c:263)
Nov 15 14:36:54 downloads transmission-daemon[66003]: Unable to save pidfile "/usr/pbi/transmission-amd64/etc/transmission/transmission.pid": Permission denied (daemon.c:573)

I've checked service transmission status and there is no additional service running and I've also done a killall transmission command which indicates no service being run.

I'm thinking this has to do with permission or the port 51413.

Hoping anyone can help out here.
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
An update tot his issue.

I was able to install the plugin in it's own jail and start the service. However if I upload the plug-in in a jail which contains other plug-ins such as sab, couchpotato, etc, the transmission plug-in fails to start.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
From reading you post it sounds like you didn't stop transmission before upgrading the plugin. I suggest trying to restart the jail that was having the issues.
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Hi Joshua,

Your right, I didn't stop the plug-in before upgrading. I've already restarted the jail and the entire NAS without any success.

Here is an update, I've resolved the permission issue and I'm down to the following errors:

Nov 15 16:20:49 downloads transmission-daemon[58952]: Couldn't bind port 51413 on 0.0.0.0: Address already in use (Is another copy of Transmission already running?) (net.c:371)
Nov 15 16:20:49 downloads transmission-daemon[58952]: Couldn't bind port 51413 on ::: Address already in use (Is another copy of Transmission already running?) (net.c:371)
Nov 15 16:20:49 downloads transmission-daemon[58952]: UDP Couldn't bind IPv4 socket (tr-udp.c:263)
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Hi Joshua,

Your right, I didn't stop the plug-in before upgrading. I've already restarted the jail and the entire NAS without any success.

Here is an update, I've resolved the permission issue and I'm down to the following errors:

Nov 15 16:20:49 downloads transmission-daemon[58952]: Couldn't bind port 51413 on 0.0.0.0: Address already in use (Is another copy of Transmission already running?) (net.c:371)
Nov 15 16:20:49 downloads transmission-daemon[58952]: Couldn't bind port 51413 on ::: Address already in use (Is another copy of Transmission already running?) (net.c:371)
Nov 15 16:20:49 downloads transmission-daemon[58952]: UDP Couldn't bind IPv4 socket (tr-udp.c:263)
can you show the output of the following in the jail having the issues.
Code:
service transmission status
sockstat | grep 51413
service transmission start
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Here is the output:

1.
transmission is not running.
2.
media transmissi 98648 9 tcp4 *:51413 *:*
media transmissi 98648 10 tcp6 *:51413 *:*
media transmissi 98648 11 udp4 *:51413 *:*
3.
Starting transmission.
transmission is not running.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Here is the output:

1.
transmission is not running.
2.
media transmissi 98648 9 tcp4 *:51413 *:*
media transmissi 98648 10 tcp6 *:51413 *:*
media transmissi 98648 11 udp4 *:51413 *:*
3.
Starting transmission.
transmission is not running.
please try restarting the jail and running the commands again. Transmission is running as seen by the output to number 2, but the init script isn't recognizing it for some reason.
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Your right transmission is running somewhat as the web GUI does load up.

The commands I executed above where done right after I just restarted the jail.

Could this be some residual plug-in bits that remained from previous install? Is there a way to clear it up and re-install again?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Your right transmission is running somewhat as the web GUI does load up.

The commands I executed above where done right after I just restarted the jail.

Could this be some residual plug-in bits that remained from previous install? Is there a way to clear it up and re-install again?
restarting the jail would have killed the old process. I'm not sure why there's still some process, but "kill -9 98648" should stop it.

If you don't care about saving your old settings then clearing /var/db/transmission should make it like a fresh install.
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
I performed "kill -9 98648", then restarted the transmission service again and got the following errors.

Nov 15 16:57:07 downloads transmission-daemon[43191]: UDP Couldn't bind IPv4 socket (tr-udp.c:263)
Nov 15 17:27:34 downloads transmission-daemon[75750]: UDP Failed to set receive buffer: No buffer space available (tr-udp.c:59)
Nov 15 17:27:34 downloads transmission-daemon[75750]: UDP Failed to set receive buffer: requested 4194304, got 42080 (tr-udp.c:78)

I'll see if the service still works, if not I may consider clearing the database?

Do you know the command to clear the DB?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I performed "kill -9 98648", then restarted the transmission service again and got the following errors.

Nov 15 16:57:07 downloads transmission-daemon[43191]: UDP Couldn't bind IPv4 socket (tr-udp.c:263)
Nov 15 17:27:34 downloads transmission-daemon[75750]: UDP Failed to set receive buffer: No buffer space available (tr-udp.c:59)
Nov 15 17:27:34 downloads transmission-daemon[75750]: UDP Failed to set receive buffer: requested 4194304, got 42080 (tr-udp.c:78)

I'll see if the service still works, if not I may consider clearing the database?

Do you know the command to clear the DB?
So you killed the process but you still have some UDP buffer error. Not sure what that means though. You said earlier transmission worked in another jail right?

sorry I'm not sure what you mean by clearing the database. if you mean resetting transmission like I said earlier. just delete everything in the directury with "rm -r /var/db/transmission/*"
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
So I did the following:
1. Deleted transmission plug-in from web-gui
2. "rm -r /var/db/transmission/*"
3. stopped then started my jail with all plug-ins
4. uploaded transmission package to the jail once it was started
5. tried to start transmission service from web-gui and got the error message below:

Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: No buffer space available (tr-udp.c:59)
Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: requested 4194304, got 42080 (tr-udp.c:78)
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
So I did the following:
1. Deleted transmission plug-in from web-gui
2. "rm -r /var/db/transmission/*"
3. stopped then started my jail with all plug-ins
4. uploaded transmission package to the jail once it was started
5. tried to start transmission service from web-gui and got the error message below:

Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: No buffer space available (tr-udp.c:59)
Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: requested 4194304, got 42080 (tr-udp.c:78)
the issue seems to be with something I'm not familiar with. did you get the same buffer issue with other jails? I've never personally dealt with that before.
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Looks like I resolved the permission issue by chmod the transmission directory to 777:
  • Unable to save pidfile "/usr/pbi/transmission-amd64/etc/transmission/transmission.pid": Permission denied (daemon.c:573)

I also resolved the receiver buffer issue by changing the freenas configuration settings:
  • Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: No buffer space available (tr-udp.c:59)
  • Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: requested 4194304, got 42080 (tr-udp.c:78)

Now Transmission works, however I see the following cosmetic and status issue:
  • FreeNAS webui reports the service has not started
  • Running service transmission status states the service is not running (but it actually is running)
Creating a separate jail for transmission reports the correct status of the service as running in the webui and CLI.

For now this isn't a major showstopper however would be nice to have this issue addressed.

What is unique about my situation is the following:
  • I uploaded the plug-in to the jail along with other plug-ins like SAB and Sickrage
  • I have an OpenVPN service also running on this jail
  • I have firewall rules that only allow communication to go out to the internet if there is a VPN tunnel established (don't think this would cause the problem though)
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Looks like I resolved the permission issue by chmod the transmission directory to 777:
  • Unable to save pidfile "/usr/pbi/transmission-amd64/etc/transmission/transmission.pid": Permission denied (daemon.c:573)

I also resolved the receiver buffer issue by changing the freenas configuration settings:
  • Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: No buffer space available (tr-udp.c:59)
  • Nov 15 19:12:17 downloads transmission-daemon[40836]: UDP Failed to set receive buffer: requested 4194304, got 42080 (tr-udp.c:78)

Now Transmission works, however I see the following cosmetic and status issue:
  • FreeNAS webui reports the service has not started
  • Running service transmission status states the service is not running (but it actually is running)
Creating a separate jail for transmission reports the correct status of the service as running in the webui and CLI.

For now this isn't a major showstopper however would be nice to have this issue addressed.

What is unique about my situation is the following:
  • I uploaded the plug-in to the jail along with other plug-ins like SAB and Sickrage
  • I have an OpenVPN service also running on this jail
  • I have firewall rules that only allow communication to go out to the internet if there is a VPN tunnel established (don't think this would cause the problem though)
hmm, I'm wondering why transmission is putting the pidfile there. can you show the output of the following.
ls -l /usr/pbi/transmission-amd64/etc/transmission
cat /etc/rc.conf | grep transmission
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Here is what I get:
1.
drwxr-xr-x 2 transmission transmission 2 Jul 7 00:59 home
-rw-rw-rw- 1 media wheel 5 Nov 15 19:58 transmission.pid

2.
transmission_conf_dir="/var/db/transmission"
transmission_flags=""
transmission_download_dir=""
transmission_enable="YES"
 

EscapeVelocit3y

Dabbler
Joined
Oct 11, 2014
Messages
28
Following commands solved my issue.

rm /usr/local/etc/rc.d/transmission
ln -s /usr/pbi/transmission-amd64/etc/rc.d/transmission /usr/local/etc/rc.d
 
Status
Not open for further replies.
Top