Skip to content

Instantly share code, notes, and snippets.

Created March 31, 2017 17:48
Show Gist options
  • Save anonymous/b10f476a95ae9cdd39b83ef872d4b1e6 to your computer and use it in GitHub Desktop.
Save anonymous/b10f476a95ae9cdd39b83ef872d4b1e6 to your computer and use it in GitHub Desktop.
postgres=# create schema test;
CREATE SCHEMA
postgres=# SECURITY LABEL for selinux on schema test IS 'system_u:object_r:sepgsql_schema_t:s0';
SECURITY LABEL
postgres=# create table test.t1p ( logdate date not null ) partition by range (logdate);
CREATE TABLE
postgres=# create table test.t1p_jan partition of test.t1p for values from ('2017-01-01') to ('2017-02-01');
CREATE TABLE
postgres=# select * from pg_seclabels;
objoid | classoid | objsubid | objtype | objnamespace | objname | provider | label
--------+----------+----------+---------+--------------+-----------------------+----------+------------------------------------------
16503 | 1259 | 0 | table | 16499 | test.t1p_jan | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | 0 | table | 16499 | test.t1p | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | -7 | column | 16499 | test.t1p_jan.tableoid | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | -7 | column | 16499 | test.t1p.tableoid | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | -6 | column | 16499 | test.t1p.cmax | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | -5 | column | 16499 | test.t1p.xmax | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | -4 | column | 16499 | test.t1p.cmin | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | -3 | column | 16499 | test.t1p.xmin | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | -1 | column | 16499 | test.t1p.ctid | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16500 | 1259 | 1 | column | 16499 | test.t1p.logdate | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | -6 | column | 16499 | test.t1p_jan.cmax | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | -5 | column | 16499 | test.t1p_jan.xmax | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | -4 | column | 16499 | test.t1p_jan.cmin | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | -3 | column | 16499 | test.t1p_jan.xmin | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | -1 | column | 16499 | test.t1p_jan.ctid | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16503 | 1259 | 1 | column | 16499 | test.t1p_jan.logdate | selinux | unconfined_u:object_r:sepgsql_table_t:s0
16499 | 2615 | 0 | schema | 16499 | test | selinux | system_u:object_r:sepgsql_schema_t:s0
(17 rows)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment