diff --git a/src/backend/commands/indexcmds.c b/src/backend/commands/indexcmds.c
new file mode 100644
index fdfa6ca..4f31678
*** a/src/backend/commands/indexcmds.c
--- b/src/backend/commands/indexcmds.c
*************** DefineIndex(Oid relationId,
*** 489,494 ****
--- 489,498 ----
  	accessMethodId = HeapTupleGetOid(tuple);
  	accessMethodForm = (Form_pg_am) GETSTRUCT(tuple);
  
+ 	if (strcmp(accessMethodName, "hash") == 0)
+ 		ereport(WARNING,
+ 				(errmsg("hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves")));
+ 
  	if (stmt->unique && !accessMethodForm->amcanunique)
  		ereport(ERROR,
  				(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
diff --git a/src/test/regress/expected/create_index.out b/src/test/regress/expected/create_index.out
new file mode 100644
index f6f5516..7a0185a
*** a/src/test/regress/expected/create_index.out
--- b/src/test/regress/expected/create_index.out
*************** DROP TABLE array_gin_test;
*** 2238,2246 ****
--- 2238,2250 ----
  -- HASH
  --
  CREATE INDEX hash_i4_index ON hash_i4_heap USING hash (random int4_ops);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  CREATE INDEX hash_name_index ON hash_name_heap USING hash (random name_ops);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  CREATE INDEX hash_txt_index ON hash_txt_heap USING hash (random text_ops);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  CREATE INDEX hash_f8_index ON hash_f8_heap USING hash (random float8_ops);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  -- CREATE INDEX hash_ovfl_index ON hash_ovfl_heap USING hash (x int4_ops);
  --
  -- Test functional index
diff --git a/src/test/regress/expected/enum.out b/src/test/regress/expected/enum.out
new file mode 100644
index 3682642..774f6fc
*** a/src/test/regress/expected/enum.out
--- b/src/test/regress/expected/enum.out
*************** DROP INDEX enumtest_btree;
*** 383,388 ****
--- 383,389 ----
  -- Hash index / opclass with the = operator
  --
  CREATE INDEX enumtest_hash ON enumtest USING hash (col);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  SELECT * FROM enumtest WHERE col = 'orange';
    col   
  --------
diff --git a/src/test/regress/expected/macaddr.out b/src/test/regress/expected/macaddr.out
new file mode 100644
index 50d0369..0657df1
*** a/src/test/regress/expected/macaddr.out
--- b/src/test/regress/expected/macaddr.out
*************** SELECT * FROM macaddr_data;
*** 39,44 ****
--- 39,45 ----
  
  CREATE INDEX macaddr_data_btree ON macaddr_data USING btree (b);
  CREATE INDEX macaddr_data_hash ON macaddr_data USING hash (b);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  SELECT a, b, trunc(b) FROM macaddr_data ORDER BY 2, 1;
   a  |         b         |       trunc       
  ----+-------------------+-------------------
diff --git a/src/test/regress/expected/replica_identity.out b/src/test/regress/expected/replica_identity.out
new file mode 100644
index 96dc98b..62c1f95
*** a/src/test/regress/expected/replica_identity.out
--- b/src/test/regress/expected/replica_identity.out
*************** CREATE INDEX test_replica_identity_keyab
*** 11,16 ****
--- 11,17 ----
  CREATE UNIQUE INDEX test_replica_identity_keyab_key ON test_replica_identity (keya, keyb);
  CREATE UNIQUE INDEX test_replica_identity_nonkey ON test_replica_identity (keya, nonkey);
  CREATE INDEX test_replica_identity_hash ON test_replica_identity USING hash (nonkey);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  CREATE UNIQUE INDEX test_replica_identity_expr ON test_replica_identity (keya, keyb, (3));
  CREATE UNIQUE INDEX test_replica_identity_partial ON test_replica_identity (keya, keyb) WHERE keyb != '3';
  -- default is 'd'/DEFAULT for user created tables
diff --git a/src/test/regress/expected/uuid.out b/src/test/regress/expected/uuid.out
new file mode 100644
index d907519..e388ca2
*** a/src/test/regress/expected/uuid.out
--- b/src/test/regress/expected/uuid.out
*************** SELECT COUNT(*) FROM guid1 WHERE guid_fi
*** 114,119 ****
--- 114,120 ----
  -- btree and hash index creation test
  CREATE INDEX guid1_btree ON guid1 USING BTREE (guid_field);
  CREATE INDEX guid1_hash  ON guid1 USING HASH  (guid_field);
+ WARNING:  hash indexes are not WAL-logged so they are not crash-safe and cannot be used on streaming slaves
  -- unique index test
  CREATE UNIQUE INDEX guid1_unique_BTREE ON guid1 USING BTREE (guid_field);
  -- should fail
