It took me a while to figure it out, and both of my parents are attorneys. I worked as an RA over the summer for a professor who focused on international law, and ultimately it just wasn't my thing. I thought about plaintiffs work in labor and employment, which is what my father practices, but what really piqued my interest in 1L were civil procedure and criminal law. This year, my favorite classes are Criminal Procedure, Evidence, Constitutional Law and Conflicts of Law. I still do international research for my professor and I am on an international law journal, but my immediate focus has definitely shifted to criminal defense. I took a second job at the Fair Housing Commission to explore civil rights work. My resume is all over the place.
There are plenty of opportunities out there as a 2L to explore. Even apart from electives, Jacy mentioned clinical and field placements. I would also look at positions with the City Attorney, local hospitals, judicial externships, etc. I like the staff and the work at the Fair Housing Commission, and it gives me insight into that field (which is not exactly crowded).
On the business side, a friend of mine at another law school is taking a corporate counsel seminar, which is what she wants to do, ultimately. That work is very different from a law firm, and is probably worth exploring if you have any interest.
In CA, there are continuing legal education requirements and every so often a seminar in a particular practice area is offered up. Students are usually admitted at a discounted rate, or go for free. That is another chance to talk and network with people in a variety of fields.
Another worthwhile option is a judicial clerkship. Competitive, yes, but you are exposed to a wide variety of practice areas.
Finally, the first year classes, to my mind, are not really practice areas, with the possible exception of criminal law. I wouldn't sweat not knowing what area you are interested in after the first year.