It could still very well be cancer, there's no way of knowing for sure whether it's cancer, pneumothorax, pneumonia, or any number of other things without running some tests. You shouldn't post, "IT IS NOT CANCER" when you don't know this for a fact.
Whatever it may be, lungs are very delicate organs, and any sort of pain or anything in them should be examined immediately. It doesn't matter what it is, whether it be cancer or any number of other things, you should seek professional medical help from your local physician immediately.