# How to start two arvgvfakecamera?

**URL:** <https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70>\
**Category:** Using Aravis\
**Created:** [February 4, 2020, 2:45am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70 "2020-02-04T02:45:04Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![fwanghuan](https://avatars.discourse-cdn.com/v4/letter/f/35a633/32.png) [@fwanghuan](https://aravis-project.discourse.group/u/fwanghuan)\
**Post date:** [February 4, 2020, 2:45am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/1 "2020-02-04T02:45:04Z")

</div>

Hi, can I start two arvgvfakecamera in one IP address ? Or How can I support two streams in one arvgvfakecamera at the sametime ?

I noticed it allow to instantiate several gvfakecamera since the version of aravis0.7.1, the summary of the changes as below:  
fakecamera: allow to instantiate several gvfakecamera (Emmanuel)

Actually, I want to transmit two video stream at the sametime in on IP address device. But I can’t open two gvfakecamera at the sametime.

---

<div class="post-metadata">

**Author:** ![Emmanuel](https://yyz2.discourse-cdn.com/free1/user_avatar/aravis-project.discourse.group/emmanuel/32/198_2.png) [@Emmanuel](https://aravis-project.discourse.group/u/Emmanuel)\
**Post date:** [February 4, 2020, 5:44am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/2 "2020-02-04T05:44:17Z")

</div>

Hi,

It is not possible to have two ArvGvFakeCamera instances listening on the same IP address, as they use the same incoming port. But you can configure your machine to have several IP adresses (several interfaces), then assign a different interface to each fake camera instances.

Emmanuel.

---

<div class="post-metadata">

**Author:** ![fwanghuan](https://avatars.discourse-cdn.com/v4/letter/f/35a633/32.png) [@fwanghuan](https://aravis-project.discourse.group/u/fwanghuan)\
**Post date:** [February 10, 2020, 5:35am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/3 "2020-02-10T05:35:41Z")

</div>

Hi,

Thanks. Is it possible to have two gvsp video streams on one fake camera?

---

<div class="post-metadata">

**Author:** ![Emmanuel](https://yyz2.discourse-cdn.com/free1/user_avatar/aravis-project.discourse.group/emmanuel/32/198_2.png) [@Emmanuel](https://aravis-project.discourse.group/u/Emmanuel)\
**Post date:** [February 10, 2020, 7:19am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/4 "2020-02-10T07:19:24Z")

</div>

It is possible with respect to the standard, but not implemented in aravis.

Cheers,

Emmanuel.

---

<div class="post-metadata">

**Author:** ![fwanghuan](https://avatars.discourse-cdn.com/v4/letter/f/35a633/32.png) [@fwanghuan](https://aravis-project.discourse.group/u/fwanghuan)\
**Post date:** [February 13, 2020, 2:48am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/5 "2020-02-13T02:48:45Z")

</div>

> [@Emmanuel](#):
>
> But you can configure your machine to have several IP adresses

Hi, emmanuel

Thanks for response. You said that we can configure our machine to have several IP adresses. How can I configure it to have serveral IP?

Should I install another more physical hardware on my machine?

Or just use ifconfig to configure the machine ?

And then, I try to use ifconfig to configrue have another more IP addresses, like this: ifconfig eth0:1 192.168.0.180 up

But I use the aravis-arv-fake-gv-camera-0.8 to open the second gvfake, it also errors. The details as below:

root@ck-virtual-machine:/home/ck/working/IndustryCameraSdk/aravis-0.7/aravis-bin/bin# ./arv-fake-gv-camera-0.8 -i eth0:1 -s GV12 -d all  
GVSP address = 192.168.0.180  
GVCP address = 192.168.0.180:3956  
Global discovery address = 255.255.255.255:3956  
Subnet discovery address = 192.168.0.255:3956  
Failed to bind socket: Error binding to address: Address already in use  
Failed to start camera

---

<div class="post-metadata">

**Author:** ![Emmanuel](https://yyz2.discourse-cdn.com/free1/user_avatar/aravis-project.discourse.group/emmanuel/32/198_2.png) [@Emmanuel](https://aravis-project.discourse.group/u/Emmanuel)\
**Post date:** [February 13, 2020, 8:56am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/6 "2020-02-13T08:56:49Z")

</div>

> [@fwanghuan](#):
>
> Or just use ifconfig to configure the machine ?

ifconfig should work, you don’t need a physical interface.

> [@fwanghuan](#):
>
> Failed to bind socket: Error binding to address: Address already in use

There was a commit that was specifically for this issue: [global discovery socket needs to be marked SO\_REUSEPORT to allow by highperformancecoder · Pull Request #276 · AravisProject/aravis · GitHub](https://github.com/AravisProject/aravis/pull/276)

Do you use aravis master ?

Could you open a bug report, explaining how you are configuring the interfaces. Please run your tests with -d all:3 .

Thanks.

Emmanuel.

---

<div class="post-metadata">

**Author:** ![fwanghuan](https://avatars.discourse-cdn.com/v4/letter/f/35a633/32.png) [@fwanghuan](https://aravis-project.discourse.group/u/fwanghuan)\
**Post date:** [February 18, 2020, 4:30am UTC](https://aravis-project.discourse.group/t/how-to-start-two-arvgvfakecamera/70/7 "2020-02-18T04:30:27Z")

</div>

Yes, ifconfig is work, but we should configure a new broadcast address.  
If our physical interface is wlan0, ip is 192.168.0.112, and broadcast is 192.168.0.255, and then we should use ifconfig to confgure a new fake interface as below:  
ifconfig wlan0:1 192.168.0.114 brodcast 192.168.255.255 up

and then, we can create two arv-fake-gv-camera as below:  
./arv-fake-gv-camera-0.8 -i wlan0 -s gv1  
./arv-fake-gv-camera-0.8 -i wlan0:1 -s gv2
