Conserved quantities from entanglement Hamiltonian