Ada lebih banyak contoh AWS SDK yang tersedia di repo Contoh SDK AWS Doc
Terjemahan disediakan oleh mesin penerjemah. Jika konten terjemahan yang diberikan bertentangan dengan versi bahasa Inggris aslinya, utamakan versi bahasa Inggris.
Gunakan DeleteRouteTable
dengan CLI
Contoh kode berikut menunjukkan cara menggunakanDeleteRouteTable
.
- CLI
-
- AWS CLI
-
Untuk menghapus tabel rute
Contoh ini menghapus tabel rute yang ditentukan. Jika perintah berhasil, tidak ada output yang akan ditampilkan.
Perintah:
aws ec2 delete-route-table --route-table-id
rtb-22574640
-
Untuk detail API, lihat DeleteRouteTable
di Referensi AWS CLI Perintah.
-
- PowerShell
-
- Alat untuk PowerShell V4
-
Contoh 1: Contoh ini menghapus tabel rute yang ditentukan. Anda diminta untuk konfirmasi sebelum operasi berlangsung, kecuali jika Anda juga menentukan parameter Force.
Remove-EC2RouteTable -RouteTableId rtb-1a2b3c4d
Output:
Confirm Are you sure you want to perform this action? Performing operation "Remove-EC2RouteTable (DeleteRouteTable)" on Target "rtb-1a2b3c4d". [Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"):
-
Untuk detail API, lihat DeleteRouteTabledi Referensi Alat AWS untuk PowerShell Cmdlet (V4).
-
- Alat untuk PowerShell V5
-
Contoh 1: Contoh ini menghapus tabel rute yang ditentukan. Anda diminta untuk konfirmasi sebelum operasi berlangsung, kecuali jika Anda juga menentukan parameter Force.
Remove-EC2RouteTable -RouteTableId rtb-1a2b3c4d
Output:
Confirm Are you sure you want to perform this action? Performing operation "Remove-EC2RouteTable (DeleteRouteTable)" on Target "rtb-1a2b3c4d". [Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"):
-
Untuk detail API, lihat DeleteRouteTabledi Referensi Alat AWS untuk PowerShell Cmdlet (V5).
-