I know intro abstract algebra and some real analysis. Is this enough to study algebraic geometry from the book of Hartshorne?
I think you will need significantly more background in modern algebra. Firstly, you should probably learn the elements of point-set topology; I would recommend chapters 2-3 of Munkres' Topology: A First Course. Secondly, you should probably learn the theory of fields in some depth. In addition to the elements of Galois theory, a couple of important topics relevant to commutative algebra in the theory of fields include the theory of separable and inseparable extensions and the theory of transcendental extensions. I would recommend Algebra: A Graduate Course by Martin Isaacs.
After you have studied point-set topology and the theory of fields in some depth, I would recommend you to read An Introduction to Commutative Algebra by Atiyah and Macdonald and do most or all of the exercises in this textbook. (The exercises are important because, for one reason, they introduce the reader to affine schemes which are the basic "building blocks" of schemes.) If you are the sort of person who does not like to accept mathematical facts without proof (and, if you are, it is not bad by any means), then you should also read Commutative Algebra by Hideyuki Matsumura.
However, before you begin reading Matsumura's textbook, you should briefly learn the elements of homological algebra: from my reading of Matsumura, it seems that the most important aspects of homological algebra which you will need to know are: projective and injective modules, the Tor and Ext functors, and perhaps a very elementary knowledge of the language of category theory. The best place, I think, to learn this material is Appendix B of Matsumura's Commutative Ring Theory. Once you have finished Matsumura's textbook (Commutative Algebra), you probably have exactly the background necessary to read Hartshorne.
In pratice, I think most people do not read Matsumura's Commutative Algebra before Hartshorne's Algebraic Geometry but I could be wrong. If you are willing to accept facts in commutative algebra without proof, then it might be OK for you to defer your reading of Matsumura's textbook or to read Matsumura's textbook concurrently with Hartshorne. Alternatively, if you are interested in number theory (or not), you could read Qing Liu's Algebraic Geometry and Arithmetic Curves directly after Atiyah and Macdonald's textbook; the commutative algebra necessary to read Liu's textbook is minimal.