gshared must be restarted

Bug #55262 reported by Khashayar Naderehvandi
4
Affects Status Importance Assigned to Milestone
GShare
Incomplete
High
Celso Pinto

Bug Description

I seem to have to restart gshared every now and then; most notably after a suspend-resume-cycle, and sometimes just after a login. When it works, though, it seems to work flawlessly.

Celso Pinto (cpinto)
Changed in gshare:
assignee: nobody → cpinto
importance: Untriaged → High
Revision history for this message
Celso Pinto (cpinto) wrote :

Khashayar,

I've been running GShare in debug mode for the past days with lots of suspend-to-ram/resume cycles and I can't seem to reproduce this problem.

Everytime I resume the computer I execute the "avahi-browse -a" command and this shows me that GShare is indeed advertised. I'm running an older GNOME 2.12 version and Nautilus seems to have some problems displaying remote shares (actually, it doesn't display any remote shares) but this is something I already knew.

I'd like to ask you a couple of things:
- first, when you resume your computer and shares do not show in the Network Browser, can you please run the above mentioned command (avahi-browse -a ) in a gnome-terminal and see if the remote shares are being advertised or not

- second, can you let me know what system are you running. The info I'd like to get from you, if possible, is the Linux distribution (and version) and GNOME version (or KDE if applicable). From there I should be able to try and figure out what versions of the GShare dependencies you have in your system.

Changed in gshare:
status: Unconfirmed → Needs Info
Revision history for this message
Khashayar Naderehvandi (khashayar) wrote :

Celso,

The system I'm running is Archlinux with a 2.6.17-beyond3 kernel. The mono version is 1.1.16.1. Gnome version is 2.14.

Gshared is started automatically with a gnome session. As I sit here now, I have had no internet connection for some time under the same gnome session. Connecting the computer first and then running avahi-browse -a does not show my gshare-share. I then tried to shutdown gshare with gshared --shutdown to restart it, but received this:

Service terminated

=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================

Stacktrace:

  at (wrapper managed-to-native) System.Threading.Monitor.Monitor_try_enter (object,int) <0x00004>
  at (wrapper managed-to-native) System.Threading.Monitor.Monitor_try_enter (object,int) <0xffffffff>
  at System.Threading.Monitor.Enter (object) <0x00013>
  at (wrapper synchronized) DBus.Service.remove_SignalCalled (DBus.Service/SignalCalledHandler) <0xffffffff>
  at GShare.GShareService.Proxy.Finalize () <0x00015>
  at (wrapper runtime-invoke) System.Object.runtime_invoke_void (object,intptr,intptr,intptr) <0xffffffff>

Native stacktrace:

        /usr/bin/mono(mono_handle_native_sigsegv+0xe7) [0x8144247]
        /usr/bin/mono [0x8111498]
        [0xffffe440]
        /usr/bin/mono [0x8145d73]
        [0xa7f48a37]
        [0xa7f489c4]
        [0xa7f51fbc]
        [0xa7f51f8e]
        [0xa7f51f09]
        /usr/bin/mono [0x81466d1]
        /usr/bin/mono [0x81467e4]
        /usr/bin/mono [0x80be642]
        /usr/bin/mono [0x80f3bd7]
        /usr/bin/mono [0x8100853]
        /lib/libpthread.so.0 [0xa7e80274]
        /lib/libc.so.6(__clone+0x5e) [0xa7dea47e]
Aborted

I then killed it with the kill command, and started it again. Now it shows just fine in both nautilus and through avahi-browse.

I will now attempt a suspend-resume cycle....

...back from suspend now and everything seems to work just fine. Gshared spits this out

** (/opt/gnome/lib/gshare/gshared.exe:19388): CRITICAL **: Zeroconf client failed to register
Xlib: unexpected async reply (sequence 0x57)!

but the share is there.

Perhaps the problem is not tied to suspend/resume, but rather to something else. Perhaps the problem arises when gshared is started before there is a working network connection.

Hope this helps. Thanks for taking a look into it.

Khashayar

Revision history for this message
Khashayar Naderehvandi (khashayar) wrote :

After a while, I now get this from gshared:

Unhandled Exception: System.ObjectDisposedException: The object was used after being disposed.
  at System.Net.Sockets.Socket.Shutdown (SocketShutdown how) [0x00000]
  at GShare.FTP.ClientFTPSession.CheckConnectionTimeout (System.Object data) [0x00000]
  at (wrapper delegate-invoke) System.MulticastDelegate:invoke_void_object (object)
  at System.Threading.Timer+Runner.WaitForDueTime () [0x00000]
  at System.Threading.Timer+Runner.Start () [0x00000]
  at (wrapper delegate-invoke) System.MulticastDelegate:invoke_void ()

"avahi-browse -a" doesn't show my shared files any longer and nautilus shows a file name called "dnssd-local-Khashayar Naderehvandi's Shared Files._ftp._tcp.local" and cannot access any shares.

Restarting gshared (by first killing it with the kill command) fixes everything again.

Revision history for this message
Celso Pinto (cpinto) wrote :

I was about to download an Arch Linux iso but I have no idea of what version I should get. Can you give me some instructions to get me started with Arch Linux?

What I really need is:
1) what version of Arch Linux should I get;
2) how do I install extra packages (including setting up remote repositories if this is necessary).

I need this because I'd really like to reproduce the problem instead of reviewing the code line by line since I can't reproduce the problem. Also, would you mind asking the package maintainer to update the package to the latest GShare version (I understand that ArchLinux's version is 0.91 and I've released 0.92 a while ago and that last release included some fixes that may help).

To clear things up a bit, when I resume my laptop with GShare already running and I do an avahi-browse -a, indeed nothing shows until the network is up but then everything is fine.

Revision history for this message
Khashayar Naderehvandi (khashayar) wrote :

To install archlinux you should just get the latest iso (0.7.2, I believe), but the thing with archlinux is that it doesn't have a stable branch in the sense that e.g. debian does, so packages are updated regularly in a "rolling release" and tried to be kept up-to-date and stable. The isos are just snapshots, so first thing you do after installing is to edit /etc/pacman.conf and enable all the repositories. The configuration file is well commented. I would advise you, though, to move the entry of the "testing repository" below all others. This way you will have "testing" enabled but packages won't be installed from there unless you specifically would want it.

After that just update the entire system with this command: "pacman -Suy".

By default there's not much installed on an archlinux installation, so you would probably want to "pacman -S gnome" and "pacman -S gnome-extra". "gshare" is in the community repository, "pacman -S gshare" will give you that as well as mono 1.1.16.1. And this the problem, I think, with why gshare isn't updated to 0.92. I'm myself running the cvs version where you've fixed the compilation issues.

A really nice thing with archlinux is the package management system which allows you to easily write "PKGBUILD"s to create packages. I have edited the community PKGBUILD of version 0.91 to get the cvs snapshot instead. If you want to install gshare with this PKGBUILD, what you need to do is to extract the tarball I'm attaching to /var/abs/local, change directory to gshare-cvs and run versionpkg (make sure to install versionpkg with "pacman -S versionpkg"). This will give you a package (probably in your current directory [you can check out the settings in /etc/makepkg.conf]), which you can install directly with pacman -U $filename.

I hope this helps somewhat. You should definitely check out the you use of pacman and makepkg/ABS.

Revision history for this message
Celso Pinto (cpinto) wrote :

Khashayar I just wanted to let you know that I'm finally installing ArchLinux and looking into this problem. I expect to have some more info during the course of this week.

Revision history for this message
Khashayar Naderehvandi (khashayar) wrote :

Sounds great. Thanks :)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.