<p>Try</p>

<pre><code>bitcoind -bind=127.0.0.1 -connect=127.0.0.1
</code></pre>

CC BY-SA 3.0
2013-12-12T14:37:40.737Z
strange, when im doing -connect=127.0.0.1 it opens only port 8332, but without this option it also opens 8333 port. I believe that commands like "VERSION" i should send to 8333 port because 8332 doesn't answer me at all.
Anderson
CC BY-SA 3.0
2013-12-12T14:59:10.413Z
You're right. It seems that it goes in RPC mode. Adding `-listen=1` enables 8333. If that doesn't work. `bitcoind -bind=127.0.0.1` should do it.
Let what works for you.
Sev
CC BY-SA 3.0
2013-12-12T15:07:52.943Z
I meant `bitcoind -bind=127.0.0.1 -connect=127.0.0.1`
Sev
CC BY-SA 3.0
2013-12-13T15:16:52.843Z
I found another method, run the bitcoind as usual and add firefwall rule  sudo iptables -A OUTPUT -p tcp --out-interface wlan0 --dport 8333  -j DROP
Anderson
CC BY-SA 3.0
2013-12-12T14:26:33.407Z
2013-12-12T15:17:05.990Z
2013-12-12T15:17:05.990Z
Sev
<p>I've started to implement my bitcoin client to learn the protocol and faced a problem to see debugging output. When I start bitcoind with -debug option, it start to print so many debug messages in such speed that i can't see whats wrong with my client implementation. How can I start the bitcoind program in such way that it will not sync and just listen to new connections from local machine?</p>

<bitcoind>
How to allow only local connections?
Anderson
# How to allow only local connections?

(Asked by: username_0 on 2013-12-12)

I've started to implement my bitcoin client to learn the protocol and faced a problem to see debugging output. When I start bitcoind with -debug option, it start to print so many debug messages in such speed that i can't see whats wrong with my client implementation. How can I start the bitcoind program in such way that it will not sync and just listen to new connections from local machine?

**Tags:** bitcoind


---

## 1 answers

### Answer by username_1 on 2013-12-12. Score: 1 | Accepted answer

Try

```
bitcoind -bind=127.0.0.1 -connect=127.0.0.1

```

> **Comments:**
> **username_0**: strange, when im doing -connect=127.0.0.1 it opens only port 8332, but without this option it also opens 8333 port. I believe that commands like "VERSION" i should send to 8333 port because 8332 doesn't answer me at all.  
> **username_1**: You're right. It seems that it goes in RPC mode. Adding `-listen=1` enables 8333. If that doesn't work. `bitcoind -bind=127.0.0.1` should do it. Let what works for you.  
> **username_1**: I meant `bitcoind -bind=127.0.0.1 -connect=127.0.0.1`  
> **username_0**: I found another method, run the bitcoind as usual and add firefwall rule  sudo iptables -A OUTPUT -p tcp --out-interface wlan0 --dport 8333  -j DROP  

---

