08-18-2008
Hi
Could you please tell us what is the value set for .sin_port ? This should be the port the server is listening to... and client should also have the same port set for .sin_port as like server to get connected
Regards
Collins
10 More Discussions You Might Find Interesting
1. Programming
Problem
- Linux Client/Server Socket Application: Preventing Client from quitting on server crash
Hi,
I am writing a Linux socket Server and Client using TCP protocol on Ubuntu 9.04 x64.
I am having problem trying to implement a scenario where the client should keep running even when the... (2 Replies)
Discussion started by: varun.nagpaal
2 Replies
2. Solaris
how dow you complie perl module DBI with mysql from /usr/local/mysql/bin
keeps going to mysql client for /usr/sfw/bin
is it the LD_PATH ???...:confused:
error is
# perl login.cgi
DBI connect('customers;mysql_socket=/tmp/mysql.sock:localhost','root',...) failed: Client does not... (1 Reply)
Discussion started by: photon
1 Replies
3. Programming
Please help!
We are upgrading our server to a new Power7/AIX6.1 from Power5/AIX5.3. I have some programs that rely on output of the TOP command to do various things, however, I keep getting an error when I try to re-compile TOP on my new server (see below). I have tried TOP 3.7 (current... (1 Reply)
Discussion started by: troym72
1 Replies
4. Solaris
I have curl compiled into /usr/local. I needed to install another version into /usr/local/curl-7.19.5 and compile php using that directory. I believe I had done that but an ldd run against php shows it is using /usr/local/lib. I have my configure script below showing how it was built and php -i... (1 Reply)
Discussion started by: csgonan
1 Replies
5. Windows & DOS: Issues & Discussions
Hi All,
I need your expertise in finding a way to solve my problem.Please excuse if this is not the right forum to ask this question and guide me to the correct forum,if possible.
I am a DBA and on a daily basis i have to ftp huge dump files from my company server to my laptop and then... (3 Replies)
Discussion started by: kunwar
3 Replies
6. Solaris
Hi folks
I am trying to compile SSCEP (Simple SCEP client for Unix) on Solaris 10 box. SSCEP - Simple SCEP client for Unix
The errror is "ld: fatal: Symbol referencing errors. No output written to"
$ make
gcc -Wall -O -lcrypto -o sscep sscep.o init.o net.o sceputils.o pkcs7.o ias.o... (2 Replies)
Discussion started by: slashdotweenie
2 Replies
7. UNIX for Dummies Questions & Answers
I have just installed OpenBSD on a 333MHz PPC iMac G3. It has a 6GB HDD that has been partitioned as 1GB MacOS 8.5.1, 3GB MacOS X 10.3.9, 2GB OpenBSD 4.8. I now need to install a bootloader so that my computer can recognize the OpenBSD partition at startup. I have been trying to install... (0 Replies)
Discussion started by: t04st3r
0 Replies
8. Programming
If I have two files server.c and client.c, how do you demonstate the client reading something from the server?
so say i have a server,c and a client.c file in a unix machine (same folder), and i want the client to connect and write something to server (through the internet), then server returns it... (2 Replies)
Discussion started by: omega666
2 Replies
9. Shell Programming and Scripting
hi, i am new to unix,
cuold u send some sftp acripts to send files to dev server to clint server, (1 Reply)
Discussion started by: Koti.annam
1 Replies
10. UNIX for Advanced & Expert Users
Hello. Trying to compile Pango with one or mentioned packages as backend, Cairo or X11 related packages I have been facing a series of error messages that I do not know how to fix.
First with Cairo. I try to compile Pango with ./configure ... (1 Reply)
Discussion started by: colt
1 Replies
LEARN ABOUT MOJAVE
bindresvport
BINDRESVPORT(3) BSD Library Functions Manual BINDRESVPORT(3)
NAME
bindresvport, bindresvport_sa -- bind a socket to a privileged IP port
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <sys/types.h>
#include <rpc/rpc.h>
int
bindresvport(int sd, struct sockaddr_in *sin);
int
bindresvport_sa(int sd, struct sockaddr *sa);
DESCRIPTION
The bindresvport() and bindresvport_sa() functions are used to bind a socket descriptor to a privileged IP port, that is, a port number in
the range 0-1023.
If sin is a pointer to a struct sockaddr_in then the appropriate fields in the structure should be defined. Note that sin->sin_family must
be initialized to the address family of the socket, passed by sd. If sin->sin_port is '0' then an anonymous port (in the range 600-1023)
will be chosen, and if bind(2) is successful, the sin->sin_port will be updated to contain the allocated port.
If sin is the NULL pointer, an anonymous port will be allocated (as above). However, there is no way for bindresvport() to return the allo-
cated port in this case.
Only root can bind to a privileged port; this call will fail for any other users.
Function prototype of bindresvport() is biased to AF_INET socket. The bindresvport_sa() function acts exactly the same, with more neutral
function prototype. Note that both functions behave exactly the same, and both support AF_INET6 sockets as well as AF_INET sockets.
RETURN VALUES
The bindresvport() function returns the value 0 if successful; otherwise the value -1 is returned and the global variable errno is set to
indicate the error.
ERRORS
[EPFNOSUPPORT] If second argument was supplied, and address family did not match between arguments.
The bindresvport() function may also fail and set errno for any of the errors specified for the calls bind(2), getsockopt(2), or
setsockopt(2).
SEE ALSO
bind(2), getsockopt(2), setsockopt(2), ip(4)
BSD
November 22, 1987 BSD