Networking :: Create The IPV6 Socket
Mar 14, 2010I am trying to create the IPV6 socket and was wondering if anybody has any code strip which I can reuse ?
View 1 RepliesI am trying to create the IPV6 socket and was wondering if anybody has any code strip which I can reuse ?
View 1 RepliesI'm trying to create a PF_PACKET socket and send a frame to another host, I know the destination's mac address and interface index, and I want to use my own protocol no., so I defined a PROTONO as 0x2323, here's the code of sender
Code:
#define MYPTNO 0x2323
int main(int argc, char **argv)
{
intsockfd;
//struct sockaddr_inservaddr;
struct sockaddr_ll servaddr, bindaddr;
[Code]...
I have a cgi script that tries to get the IP address of a domain. the Domain is defined in Bind, yet it can not resolve it. I put the domain in the host file and it then gives a Error: unable to create socket - Permission denied
I figure I have to do some code changes to the script but here I would like an explaination as to the error I am getting.
I used to play with gw6c ( a client for tunnel broker ) It works well with fedora9 , fedora 10, but not with leonidas. my rpm is gw6c-6.0-0.4.beta4.fc9.i386.rpm ( a little old!) when I tried to install i have got this: libcrypto.so.7 est ncessaire pou w6c-6.0-0.4.beta4.fc9.i386 I try to make a soft link to libcrypto.so.0.9.8k, but nothing; The question :-Is there a solution for that pb - did you know a better client for non native ipv6 connectivity?
View 2 Replies View RelatedI have been struggling to get FC15 to act as an IPv6 router for a while now, am sure I am missing something trivial.. The idea is that I have a ppp / adsl connection (this works fine), use the wireless card on my pc with hostapd and dhcpd to provide connections to other pcs (works fine), and radvd to delegate ipv6 addresses.
The issue seem to be that as soon as I turn on ipv6 forwarding (net.ipv6.conf.all.forwarding =1), the ppp connection no longer gets an IPv6 address. This means the router cannot ping any ipv6 address outside my network.
If I disable ipv6 routing, my router gets an IPv6 address on its ppp connection, and can ping things such as ipv6.google.com just fine, however (of course) no packets are forwarded from my network and radvd complains that forwarding is disabled.
I want to configure socket timer to release socket(port) once the connection is terminated. Do we have something in Linux OS to configure this delay to release socket?.
Any command, link or man-page anything will be helpful.
I browsed a lot but unable to find it.
I had installed Fedora 10
Below is the output of uname -a
Linux 2.6.27.5-117.fc10.i686.PAE #1 SMP Tue Nov 18 12:08:10 EST 2008 i686 i686 i386 GNU/Linux
I need to enable telnet service on it, then found xinetd and telnet-server not installed,
Then I had installed below
First I had installed Xinetd: xinetd-2.3.14-21.fc10.i386.rpm
then I had installed telnet-server: xinetd-2.3.14-21.fc10.i386.rpm
After installation I executed below commands
Service xinetd start
Chkconfig xinetd on
Chkconfig telnet on
Service iptables stop
Chkconfig iptables off
Iptables �F
After I had tried telnet localhost ----IT FAILED
when I run telnet server manually by issuing the below command
/usr/sbin/in.telnetd, I get below error
[COLOR="Red"]/usr/sbin/in.telnetd: getpeername: Socket operation on non-socket[/COLOR]
I have other system running same OS, I had followed the same steps discussed above to enable telnet, It works fine on it.
I am running vsftp on one of my systems and when trying to connect to it it errors out with this: vendion@Loki:~> ftp 192.168.1.100 Connected to 192.168.1.100. 500 OOPS: could not bind listening IPv6 socket
I have tried stopping the firewall and even disabling IPv6 nothing changed, any clues as to what is going on?
I'm trying to run Interhack (spoiled variant of Nethack) for local game. Is looking through settings I saw that:
[Code]....
When I try to start it with ih_server option it gives me that error: Code: Can't access() script Could not create socket: Connection refused I think my problem is closed port: Code: nc localhost 9999 localhost [127.0.0.1] 9999 (?) : Connection refused How do I fix this?
I am pragmatically trying to upload a list of files from my client machine to a proFTPd server I have running on Ubuntu. Every time I get several (around fifty) files into the transfer, I get the following error: Quote: Connection reset by peer: socket write error
I am able to remotely upload 25,000 small files of ~ 1K in size, but when I go to upload hundreds of 2-4 Mb files, I get a socket write error. Am I using up all available sockets before they can be released? If so, how do I release the sockets? If not, what does this error mean and why am I getting it?
I am writing a ping kind of program for my own application. This application needs to run with non root user privileges. This needs me to create a raw socket. But the ping connection is failing because of creating raw socket with non root user.How can I run the application successfully with non root user privileges using raw socket creation?
View 4 Replies View RelatedI can't seem to get on my Twinkle SIP Phone, it says: "Failed to create a UDP Socket (SIP) on port 5060 Address already in use" after that message it brings me back to the window were I'm supposed to run my profile, how do I fix this?
View 6 Replies View RelatedI have a droid phone, and I have ubuntu 9 running on it. This is done by chrooting since the phone runs a linux kernel. And it works... I have a question though. tightvncserver does work, and its able to listen on 127.0.0.1.. Its how you view your X session. So you chroot to Ubuntu, then start vncserver. Then switch back to android and login to ubuntu via vnc client. but apache, mysql, and postgresql do not work. Well. They dont seem too.. except for mysql. Mysql will start but only if you tell it not to use networking by saying skip-networking in my.cnf
Mysql says: mysqld cant create ip socket permission denied Apache2 says it can find 127.0.0.1 but doesnt actually run same with postgresql... All seem to be compiled with arm architecture. So why does tightvncwork? Why is it so special? How can it listen on the loop back (127.0.0.1) when nothing else can...
I have /proc and /dev bind to the chroot side. I can run ifconfig okay, and I can run /etc/init.d/networking start okay.. But apache2, mysql, etc have problems binding. I have removed apparmor even though technically its not running, but I removed it and its configuration files, just because I thought perhaps mysql looks at apparmor, but I doubted it.
Code: # traceroute -I 69.12.32.2 Note: the -i and -I options were exchangedfor compability with LBL traceroute Use -I for ICMP, and -i <ifname> to specify the interface name unable to create ICMP send socket: Permission denied Note that the command was done as root. This worked in 11.3.
And yes, it works without the "-I". But it should work with the "-I". One shouldn't have to boot into Windows, just to run "tracert" there.
Anyone knows the difference between a socket and TCP connection for connecting to an external system?
View 1 Replies View Relatedi'm writing a simple program of client socket program. Here below is the code sample which i'm writing...
Code:
//tcp_client.c
#include <stdio.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>
#include<string.h>
#include<stdlib.h>
[Code].....
the above code works fine.if we copmile and run ./a.exe 192.xx.xx.xxx 1111 and press enter it works fine..everytime it asks "Please enter the message: " and if give that will be displayed in server. but my problem is i dont want to print everytime "Please enter the message: " i just want to feed some words one by one to the socket.
im getting that error in my code for some reason. I compiled my code, and when i try to run this server it throws me an error on my call to setsocketopt(). The only way it can reach that part of my loop is if it succeeds when it calls sock() so I dont understand why the error says its an operation on a non-socket. Im just trying to set up a server to pass messages from a client to it a viceversa. Here is the code:
Code:
int main()
{
int socket_fd, new_socket_fd, k;
struct addrinfo hints, *server_info, *p;
struct sockaddr_storage peer_address;
code....
We are seeing recv err on socket 31: 0x36. What could be meaning of the error?.
View 1 Replies View RelatedI have Ubuntu 10.10 installed on my laptop. My ISP natively supports ipv6, but since last weekend, I do not get an ipv6 ip. When I use a live cd however, I do get an ipv6 ip. For as far as I can see, all settings (/etc/network/interface and the settings in network manager) are exactly the same.
Output of ifconfig:
Code:
eth0 Link encap:Ethernet HWaddr XX:XX:XX:XX:XX:XX
inet addr:XXX.XXX.XXX.XXX Bcast:XXX.XXX.XXX.XXX Mask:XXX.XXX.XXX.XXX
inet6 addr: XXXX::XXXX:XXXX:XXXX:XXXX/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
[Code].....
EDIT: is there a way to let the netwerk be automatically configured as happens during installation? It would be nice to start with a clean and new set of network config files as there were just after I installed Ubuntu on my system, without a full reinstall of my system.
I have a problem with my ipv6 connection: although I can't get ipv6 address with DHCP, I can't use ipv6 network. I tried [URL], and the tortoise is static. I want to fix it out , so I use 'ifconfig' to see my network configuration:
eth0 Link encap:Ethernet HWaddr 00:50:8d:ef:dd:06
inet addr:210.77.9.102 Bcast:210.77.11.255 Mask:255.255.252.0
inet6 addr: 2002:d24d:b64:4:250:8dff:feef:dd06/64 Scope:Global
[code]....
Some people told me that the fisrt ipv6 address was wrong and unsuitable for ipv6 connecting. I tried /ect/init.d/networking restart but it didn't work. How can I use the second address as my ipv6 address and fix the problem out ? Now it seems there is not problem with the ip adress but the route. After watching some video, I suddenly could use ipv6. I did 'ifconfig' again and nothing was different. However, the result from the command 'ip -f inet6 route' changed: the last default route was gone and there was only one default route.
I have installed Bind 9.6.1 on my linux pc. I have to resolve domain name using IPv6 address. I have made following entry in the /etc/resolv.conf file code...
address of the machine on which Bind is running. The problem is that I am not able to ping open-ims.test domain name. If I use IPv4, everything works fine but how to ping domain using IPv6.
I have also made changes in dnszone file by replacing IPv4 address with IPv6 address and also changing A to AAAA.
I want to add repository using ipv6. So, I add a xxx.repo file in /etc/yum.repos.d/. Just like it:
[sjtu6]
name=Fedora $releasever - $basearch - ftp6.xxx.xxx.xxx
baseurl=ftp://ftp6.xxx.xxx.xxx/fedora/releases/$releasever/Everything/$basearch/os/
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$basearch
I have a networking problem with my computer. Under Windows, the computer can get both v4 and v6 address via DHCP. However, the same computer can only get v4 address under Ubuntu. Does anybody know how to solve this problem?
View 3 Replies View RelatedThe goal: ipv6 connectivity using 6to4 The problem: no connectivity on some internal hosts (mixed win & debian) and no ipv6-web access on any host. Let's start with my external box. It is headless debian lenny dhcp/local-dns & cache/firewall. It has the following interfaces after a reboot:
[Code]...
My understanding is that ipv6 will auto-configure itself and that the radvd file is all that is needed by the external host to give all the ipv6 enabled internal hosts ipv6 web access. My question: How is my external host misconfigured? Or are the problems specific to the internal hosts? I am assuming that I have issues on both the external and internal hosts since some of the internals have golobal ipv6 address and some don't. I do however wish to address the external host first.
I have a host and typing ifconfig I get:
eth0 Link encap:Ethernet HWaddr 00:0E:7F:4F:E4:09
inet addr:130.130.9.9 Bcast:130.130.255.255 Mask:255.255.0.0
inet6 addr: fe80::20e:7fff:fe4f:e409/64 Scope:Link
[code]...
and to do a test i want to disable or delete the ipv6 address, but mainteining the other configured parameters. Looking on the ifcfg config file I have
DEVICE=eth0
BOOTPROTO=static
BROADCAST=130.130.255.255
[code]....
and nothing about IPv6... Then, using ifdown-ipv6 could i remove only the ipv6 address?
I have tried to disable the ipv6 support in ubuntu 9.04 32bit but the /etc/modprobe.d/aliases does not exist so I can't disable the suport as sugested for the previews versions. I need to disable it becouse it is pounding a total maihem in my vamware machines.
View 7 Replies View RelatedI would like to enable ipv6 forwarding . i have ipv6 module loaded.I added net.ipv6.conf.all.forwarding=1 in /etc/sysctl.conf .i tried reboot , did 'service network restart' .
.
Also I tried
sysctl -w net.ipv6.conf.all.forwarding=1
and
[code]....
I have a server application that uses loopback addresses to open servers on linux machine.
For IPv4 with one line of configuration I can open many servers according to the mask I use for example with 10.10.10.0/24 I can open 254 servers.
How can I do the same for IPv6 ? I am able to add loopback interfaces but only for one host. Is it possible to add for a subnet ?
If not what is the max number of addresses that I can add ?
I also saw that it add the address only to loopback lo and I can add it to lo:3 for example.
I am wondering how I can share connection with my IPv6 connection.
I am using slackware and ip6tables so far. But the problem is that IPv6 or ip6tables has no "-t nat", so how could I just simply share Internet with the computers behind the firewall?
I want to know if sysklogd supports IPv6? I have downloaded latest version of sysklogd, which is 1.5 version. But, I didn't see any information about ipv6 support.
View 1 Replies View Related