-
Notifications
You must be signed in to change notification settings - Fork 207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
failed to call nfs_mount using the qt program (compilation kit qt5.15.2 msvc2019 64 bit) on window #511
Comments
The error message for tracking RPC is: Read from socket(1120) failed, errno:10057 (Unknown error). Closing socket. |
I added this sentence to the above code snippet: nfs_set_mountport(nfs, 2049); After returning a -14 status code, the breakpoint was traced and entered into the rpc_process_deply interface implemented in pdu. c at the following location: case PROG_UNAVAIL: |
Collect a network trace with wireshark. Generally, PROG_UNAVAIL means that either NFS or Portmapper is not configured/running on the server. Run "rpcinfo" on the server. It should list a whole bunch of program such as: |
The result of running the 'rpcinfo' command is as follows: It seems to have NFS or Portmapper configured/running. |
Ok. Collect a network trace with wireshark when you try to mount the share and I can have a look. |
seeing the same issue with v6, but only on Windows. Android and macOS were confirmed to work correctly. Issue observed in Kodi, see the link just above this comment. To be precise: with v5.0.2 all's fine, with v6.0.2 the issue is reproducible, |
@sahlberg here you go. NFS server is at 192.168.1.100 |
OK.This is the collected network tracking file: |
OK.My code is written like this, can you help me analyze where the problem occurred?
}` |
Get rid of this : |
why does the issue manifest only on Windows but not on macOS / Android? |
as far as I can see, in Kodi the only windows-specific code is a few defines that are used here: https://github.com/xbmc/xbmc/blob/e7e6ee63bf222e4a5896598d5520dd509dbaef1d/xbmc/filesystem/NFSFile.cpp#L947
the defines are: https://github.com/xbmc/xbmc/blob/e7e6ee63bf222e4a5896598d5520dd509dbaef1d/xbmc/filesystem/NFSFile.cpp#L35-L40
and there's no |
Indeed, everything was normal in v5.0.2, but in v6.0.2, this issue is reproducible |
I failed to call nfs_mount using the qt program (compilation kit qt5.15.2 msvc2019 64 bit) on window, with a status code of -5 and error message: nfs_service failed, How to solve the problem that both ends of the network can be pinged? The RPC information of my Linux server is as follows:
program vers proto port service
100000 4 tcp 111
100000 3 tcp 111
100000 2 tcp 111
100000 4 udp 111
100000 3 udp 111
100000 2 udp 111
100024 1 udp 42449
100024 1 tcp 50421
100003 3 tcp 2049
100021 1 udp 36680
100021 3 udp 36680
100021 4 udp 36680
100021 1 tcp 33051
100021 3 tcp 33051
100021 4 tcp 33051
100005 1 udp 35199
100005 1 tcp 58483
100005 2 udp 50381
100005 2 tcp 35065
100005 3 udp 56087
100005 3 tcp 42365
My code snippet is as follows:
WSADATA wsaData;
#ifdef WIN32
if (WSAStartup(MAKEWORD(2,2), &wsaData) != 0) {
printf("Failed to start Winsock2\n");
return;
}
#endif
struct nfs_context *nfs = NULL;
struct nfsfh *nfsfh = NULL;
struct nfs_url *url = NULL;
struct nfsdir *nfsdir;
nfs = nfs_init_context();
if (nfs == NULL) {
printf("failed to init context\n");
return;
}
nfs_set_version(nfs, 3);
QString fp = "nfs://192.168.xxx.xxx/home/user/";
url = nfs_parse_url_full(nfs, fp.toStdString().c_str());
if (url == NULL) {
fprintf(stderr, "%s\n", nfs_get_error(nfs));
return;
}
int ret = nfs_mount(nfs, url->server, url->path);
if ( ret != 0) {
fprintf(stderr,"return ret: %d \n\r",ret);
fprintf(stderr, "Failed to mount nfs share : %s\n", nfs_get_error(nfs));
return;
}
The text was updated successfully, but these errors were encountered: