{
    "mode": "man",
    "parameter": "getrpcport",
    "section": "3",
    "url": "https://www.chedong.com/phpMan.php/man/getrpcport/3/json",
    "generated": "2026-06-13T21:22:27Z",
    "synopsis": "int\ngetrpcport(char *host, int prognum, int versnum, int proto);",
    "sections": {
        "NAME": {
            "content": "getrpcport — get RPC port number\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "int\ngetrpcport(char *host, int prognum, int versnum, int proto);\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "The getrpcport() function returns the port number for version versnum of the RPC program\nprognum running on host and using protocol proto.  It returns 0 if it cannot contact the\nportmapper, or if prognum is not registered.  If prognum is registered but not with version\nversnum, it will still return a port number (for some version of the program) indicating that\nthe program is indeed registered.  The version mismatch will be detected upon the first call to\nthe service.\n",
            "subsections": []
        },
        "AVAILABILITY": {
            "content": "The getrpcport() function is part of libtirpc.\n\nBSD                             October 6, 1987                            BSD",
            "subsections": []
        }
    },
    "summary": "getrpcport — get RPC port number",
    "flags": [],
    "examples": [],
    "see_also": []
}