iptables rule -d ! (not destination) is giving me errors

Solution 1:

You have the ! in the wrong place. It belongs before -d.

From the iptables man page:

       [!] -d, --destination address[/mask][,...]

So for example:

iptables -A OUTPUT ! -d 134.134.134.134 -j ACCEPT

Solution 2:

try to put before --option

[root@pineapple ~]#  iptables -A OUTPUT -d! 134.134.134.134 -j ACCEPT
Using intrapositioned negation (`--option ! this`) is deprecated in favor of extrapositioned (`! --option this`).

[root@pineapple ~]# iptables -A OUTPUT ! -d 134.134.134.134 -j ACCEPT
[root@pineapple ~]# iptables -nvL | grep 134
78 92618 ACCEPT     all  --  *      *       0.0.0.0/0           !134.134.134.134