There's a bunch of stuff to consider here, although a lot of it depends on your environment.
First, device flexibility. If there's an emergency update that needs a reboot of the device to take effect, are you ready to take down the combined services to deal with that update? This can become a rabbit's hole of "what if?" scenarios but it's something to think about.
Secondly, performance. Will a single device handle the encryption traffic and the routing? Will it do so for the lifetime of the product? Are you going to end up buying a "big" single replacement box because one of the functions needed more horsepower, where a "medium" and "small" box would do if they were separate?
Redundancy - this ties in to the flexibility point, do you require redundancy on any of these devices? Is it easier to maintain a single HA pair rather than multiples? Perhaps HA is only required for specific functions.
Routing - this can be fun if you've got separate devices bringing traffic in to the environment. Are they all aware of each other? Are they all aware of the (possibly) multiple paths available to each other? Simplifying down to less devices can be beneficial here, but if your environment isn't this involved you may never have to worry about it.
Additional services - are you running firewalling, traffic inspection, or threat prevention on these remote links? Are you going to need an additional "protection" box for every service you break out from the main device?
Those are some of the primary things we consider. In my opinion there isn't a simple "always do it this way" answer for this one.
Generally a router id will be set to highest loopback address if present or the highest ip address of physical interface. But most vendors provide a way to configure a specific value example:- " ip router-id 55.1.1.1". My question here is is there any restrictions for value of router-id that can be configured? any RFC recommendations ? Can i configure "255.255.255.255" as my ip router-id?
Summary
You didn't specify a protocol, so the answer is "it depends". If you're not using MPLS TE anywhere, the value of the Router ID doesn't seem to matter for OSPF, OSPFv3, BGP, ISIS or LDP. Technically in these cases, you can assign "255.255.255.255" as the 32-bit portion of the Router ID.
While these protocols are not strictly considered a routing protocol, you cannot divorce underlying IGP choices from your ability to deploy MPLS TE. Therefore, if you are using MPLS TE with OSPF TE Extensions, CR-LDP, etc... then it's recommended to assign your Router IDs as an address on the same router.
Overall Guidance: Keep it simple for your coworkers and future service deployments
While IGPs allow you to chose any value for Router IDs, you shouldn't make life harder than necessary. While you could theoretically assign Router-1's Router ID to be a Loopback address on Router 2, don't do that unless you already plan to make a bad reputation for yourself.
Anyone who has to support the infrastructure after you will hate the aforementioned decision. Furthermore, you'd be making implementation of some MPLS TE services much harder, because people would have to reassign the Router IDs to get several of the MPLS TE services up.
RFC 1142, (ISIS) - A variable length field, from 1 to 8 octets
ID System identifier a variable length field from 1 to
8 octets (inclusive). Each routeing domain employ
ing this protocol shall select a single size for the ID
field and all Intermediate systems in the routeing do
main shall use this length for the system IDs of all
systems in the routeing domain.
### [RFC 2328, Section 5 (OSPF)] - A 32-bit number
Only defines the Router ID as a 32-bit number, thus any 32-bit number can be used:
Router ID
A 32-bit number that uniquely identifies this router in the AS.
One possible implementation strategy would be to use the
smallest IP interface address belonging to the router. If a
router's OSPF Router ID is changed, the router's OSPF software
should be restarted before the new Router ID takes effect. In
this case the router should flush its self-originated LSAs from
the routing domain (see Section 14.1) before restarting, or they
will persist for up to MaxAge minutes.
RFC 4271, Section 4.2 (BGP) - A 4-octet unsigned integer representing a valid unicast IP host address
The BGP ID is defined as a "4-octet unsigned integer" in the OPEN message.
BGP Identifier:
This 4-octet unsigned integer indicates the BGP Identifier of
the sender. A given BGP speaker sets the value of its BGP
Identifier to an IP address that is assigned to that BGP
speaker. The value of the BGP Identifier is determined upon
startup and is the same for every local interface and BGP peer.
Nevertheless, in order to be syntactically correct it must be "a valid unicast IP host address".
6.2. OPEN Message Error Handling
...
If the BGP Identifier field of the OPEN message is syntactically
incorrect, then the Error Subcode MUST be set to Bad BGP Identifier.
Syntactic correctness means that the BGP Identifier field represents
a valid unicast IP host address.
Explicitly disallows any relationship between the addresses in the protocol (IPv6) and the Router ID, which is only a 32-bit number.
2.2. Removal of addressing semantics
...
o OSPF Router IDs, Area IDs and LSA Link State IDs remain at
the IPv4 size of 32-bits. They can no longer be assigned as
(IPv6) addresses.
4.2.2. Router ID
If a PE and a CE are communicating via OSPF, the PE will have an OSPF
Router ID that is valid (i.e., unique) within the OSPF domain. More
precisely, each OSPF instance has a Router ID. Different OSPF
instances may have different Router IDs.
RFC 5036, Section 3.1 (LDP) - 6 bytes, 4 of the bytes should be a valid IGP Router ID
LDP Identifier
Six octet field that uniquely identifies the label space of the
sending LSR for which this PDU applies. The first four octets
identify the LSR and MUST be a globally unique value. It SHOULD
be a 32-bit router Id assigned to the LSR and also used to
identify it in Loop Detection Path Vectors. The last two octets
identify a label space within the LSR. For a platform-wide label
space, these SHOULD both be zero.
Defines a Router ID as "a stable IP address of an LSR that is always reachable if there is any connectivity to the LSR." Thus it pretty much has to be a loopback address
In the context of this document, the term "Router ID" means a stable
IP address of an LSR that is always reachable if there is any
connectivity to the LSR. This is typically implemented as a
"loopback address"; the key attribute is that the address does not
become unusable if an interface on the LSR is down. In some cases,
this value will need to be configured. If one is using OSPF or ISIS
as the IGP in support of traffic engineering, then it is RECOMMENDED
for the Router ID to be set to the "Router Address" as defined in
[OSPF-TE], or "Traffic Engineering Router ID" as defined in [ISIS-
TE].
RFC 3630, Section 2.4.1 (OSPF-TE), requires a "stable IP address of the advertising router"
2.4.1. Router Address TLV
The Router Address TLV specifies a stable IP address of the
advertising router that is always reachable if there is any
connectivity to it; this is typically implemented as a "loopback
address". The key attribute is that the address does not become
unusable if an interface is down. In other protocols, this is known
as the "router ID," but for obvious reasons this nomenclature is
avoided here. If a router advertises BGP routes with the BGP next
hop attribute set to the BGP router ID, then the Router Address
SHOULD be the same as the BGP router ID.
Best Answer
I am only directly aware of one issue with BFD, which is CPU demand. I am currently investigating an issues with a Cisco 7301 which when pushing more traffic during our peak hours, compared to the rest of the day, BFD is sometimes timing out and routing trips over to the next link.
It seems that under high traffic volumes the router CPU usage is rising (which isn't unusual) but at about 40-50% CPU BFD packets aren't receiving enough resources.
However I have found the following information which suggests additional issues with BFD (From this NANOG presentation, there is more in the presentation, it's a good one, give it a read!)
What are the caveats?
BFD Resource Demands
BFD Resource Demands (cont’d)
BFD and L2 link-bundling