Connect S3 to other products
You can connect S3 to other products over a private network only in specific pools: in the ru-3 and ru-7 pools, you can connect to servers in Russia; in the uz-2 pool, you can connect to servers in Uzbekistan.
To connect S3 to other products over a private network, use the Global Router.
- If you do not have a Global Router yet, create one.
- Connect the other product's subnet to the Global Router.
- Create a connection subnet to link S3 to the Global Router.
- Add a static route to S3 on the servers in the other product.
- Configure access to the private S3 endpoint on the servers in the other product.
1. Create a Global Router
- In the Control panel, in the top menu, click Products and select Global Router.
- Click Create router. A limit of five global routers is set for each account.
- Enter the router name.
- Click Create.
- If the router was created with the status
ERRORor is stuck in one of the statuses, create a ticket.
2. Connect the other product's subnet to the Global Router
Dedicated server
Cloud server or Managed Kubernetes cluster
You can connect a new or existing network to the router if it is not already connected to any of the account's global routers.
-
In the control panel, on the top menu, click Products and select Global Router.
-
Go to the router page → Networks tab.
-
Click Create network.
-
Enter a network name. It will only be used in the control panel.
-
Select the Servers and Equipment service.
-
Select a location for the network.
-
Select or enter a VLAN.
-
If you want to create a network up to an internal segment (Q-in-Q), specify its tag—a number from 2 to 4094. If a network already exists for the VLAN, you must specify the Q-in-Q segment of this VLAN.
-
Enter a subnet name. It will only be used in the control panel.
-
Enter the CIDR—the IP address and mask of the private subnet. You can enter a new subnet or an existing private server subnet if it has not yet been added to any of the global routers in the account. The subnet must meet the following conditions:
- belong to the RFC 1918 private address range:
10.0.0.0/8,172.16.0.0/12or192.168.0.0/16; - have a size of at least
/29, as three addresses will be occupied by Servercore network equipment; - do not overlap with other subnets added to this router—IP addresses must not repeat across subnets on the same router;
- if a Managed Kubernetes cluster on cloud servers is included in the global router network, the subnet must not overlap with the ranges
10.10.0.0/16,10.96.0.0/12,10.250.0.0/16and10.251.0.0/24. If a cluster on dedicated servers is included in the network — with ranges10.10.0.0/16,10.222.0.0/16,10.250.0.0/16,10.251.0.0/24and172.250.0.0/14. These subnets are used for Managed Kubernetes internal addressing, and their use may lead to conflicts in the global router network.
- belong to the RFC 1918 private address range:
-
Enter the gateway IP or leave the first address from the subnet that is assigned by default. Do not assign this address to your devices to avoid network disruption.
-
Enter the service IPs or leave the last addresses from the subnet that are assigned by default. Do not assign these addresses to your devices to avoid network disruption.
-
Click Create network.
-
Optional: check the network topology on the global router. In the Control panel, in the top menu, click Products → Global Router → router page → Network map.
-
If you specified a Q-in-Q tag in step 8, you need to enable Q-in-Q technology on the switch port and configure the private network interface that you specified in step 10. Learn more in the Configure Q-in-Q section of the Q-in-Q guide.
3. Create a connection subnet to link S3 to the Global Router
-
Create a ticket. In the ticket, specify:
- Global Router ID; you can find it in the Control Panel: in the top menu, click Products → Servercore Global Router → router page → copy the ID under the router name;
- the desired CIDR for a subnet of at least
/28, which will be used as the connection subnet from the Global Router to S3. The subnet must belong to the private address range per RFC 1918:10.0.0.0/8,172.16.0.0/12`` or 192.168.0.0/16. The subnet must not overlap with other subnets added to this router—subnets on the same router must not contain duplicate IP addresses; - endpoint — a private IP address with a
/32mask to which traffic will be sent to S3. This IP address must not be part of the selected connection subnet.
-
Wait for a response from Servercore support confirming that connectivity from S3 to the Global Router has been set up. The created connection network will not be displayed in the Global Router in the Control Panel. If you need to change connectivity settings on the S3 side, create a ticket.
4. Add static routes to S3
On each server that you connect to S3, you need to configure a static route to the peering subnet via the global router.
If you are using the Global Router as the default gateway on your servers, you do not need to add routes.
If not, add the static route on the servers you need to connect to S3:
- for the destination subnet, specify the CIDR of the connection subnet you provided in the ticket in step 3;
- for the gateway, specify the address from the subnet that the corresponding server is added to and that is used as a Global Router gateway.
Dedicated server, VMware-based cloud
Cloud platform
Ubuntu
Debian
CentOS
Windows
-
Open the network configuration file:
vi /etc/netplan/01-netcfg.yaml -
At the end of the data block for the required network interface, add the route:
routes:- to: <ip_address>/<mask>via: <gateway>Specify:
<ip_address>/<mask>— the subnet to which you need to add a route, specifying the mask, for example192.168.0.0/28;<gateway>— the gateway for the current server's subnet, which is specified on the global router.
-
If you need to define multiple routes, add them sequentially in the same block, for example:
routes:- to: 192.168.0.0/28via: 172.16.0.1- to: 192.168.1.0/28via: 172.16.0.1 -
Save the file.
-
Check the settings:
sudo netplan try -
Apply the changes:
netplan apply
5. Configure access to the private S3 endpoint on servers in the other product
By default, S3 is accessed via a public domain. If a request is sent to a private IP address, the response will include a certificate mismatch error.
To avoid this error, you must map the private IP address you specified as the endpoint in step 3 to the S3 API domain in the required pool (ru-3, ru-7, or uz-2).
The configuration depends on whether your infrastructure has its own DNS recursor.
You have your own DNS recursor
You do not have a DNS recursor
Add A records on the recursor:
storage.selcloud.ru. IN A <endpoint_ip_address>
<s3_domain>. IN A <endpoint_ip_address>
Specify:
<endpoint_ip_address>— the private IP address of the endpoint you specified when creating the connection subnet in step 3;<s3_domain>— the S3 API domain in the required pool (ru-3, ru-7, or uz-2). If you are configuring connectivity for S3 in multiple pools, specify each in a separate record.