"He knows he doesn't exist" is an interesting statement since it is a direct contradiction to Descartes' cogito ergo sum. One cannot know anything without thinking. If he doesn't exist then he doesn't think or know anything, says Descartes. "Shut the f**k up, yes I do think, and anyway you're just some dead a-hole", says Deadpool.
A large part of the point of the whole routine is to subvert the notion that any fictional character, including those in Marvel's works, exists, or has knowledge or beliefs, or speaks, or takes actions. Deadpool (the work rather than the character) challenges the convenient notion of referring to in-fiction or in-canon information as "facts", because it intentionally confuses the issue of what things we're talking about when we make these statements of fact. If reading a Marvel comic actually is observing the Marvel universe, then what absurdities emerge when we consider how that universe could interact with this one?
So personally I think the only sensible short answer to "does Deadpool THINK he's breaking the 4th wall, or does Deadpool KNOW he's breaking the 4th wall?" is "well, exactly".
That is one of the things you're supposed to think about, and there is not a clear-cut answer because another of the things you're supposed to think about is the invalidity of the assumption that there can be clear-cut in-fiction answers to questions about fictional characters. Sorry fans (says Marvel), there is no such place as the Marvel Universe. You can make true statements about works of fiction set in the Marvel Universe (or any ficton, such as MCU) but strictly speaking you cannot make true statements about the fictional "entities themselves" even though that is exactly the shorthand we use when talking about fiction -- "is this true in canon?" etc.
On the surface of it, the difference between "belief" and "knowledge" depends on exactly what you construe the word "knowledge" to mean, and the field of philosophy that attempts to define knowledge is called epistemology. It is not easy. There's a classical definition that knowledge is a "true, justified, belief". This has some problems and is not generally considered by philosophers to be an adequate definition, but will probably suffice as a necessary but not sufficient condition. So, is Deadpool's belief that he is fictional both "justified" and "true"?
It's certainly true "up here" in the real world. Deadpool is a fictional character. But up here in the real world Deadpool doesn't exist as a person, and doesn't "believe" anything. So that true statement is not a belief held by Deadpool. Down there in the ficton he holds beliefs, but it's not clear whether or not it's true down there in the ficton that he doesn't exist. All of our usual instincts scream that he does exist in the ficton, and therefore in the ficton his belief that he doesn't exist is incorrect. But the writers make it so plausible. Then, the comic intentionally nests fictons in order to further confuse the issue. So probably it isn't "knowledge" since it fails the "truth" criterion except when you mix and match two different contexts (reality and the Marvel ficton), between which statements like "Deadpool can think" and "Deadpool is a person" have different truth values, and between which the statement "Deadpool exists" mean different things.
As a side note, interesting consequences of treating "existence" as a property of a hypothetical entity, alongside other properties we might ascribe to hypothetical entities, were first explored in the Western tradition by Saint Anselm when he presented in 1078 the "ontological argument" for the existence of God. This is not a novel quandary ;-)
As for whether it passes the "justified" criterion: you can look for clues in the fiction as to whether (a) he is insane, and breaks the fourth wall in a "random" direction, but the "cameraman" intentionally places the "camera" in just the right place to make him accidentally correct, or (b) he has followed a reasonable logical process to conclude that he's fictional based on observations he makes. But to do this is to miss the message that this whole process of reasoning within the ficton is intentionally subverted by the work you're reading. Deadpool and the "world" he appears to inhabit behave as the authors cause them to behave, and the authors make this more obvious than usual. The ficton does not necessarily have to behave according to logical consequences of "facts" like "Deadpool is delusional" or "Deadpool is not delusional".
Seriously, the whole point is to bake your noodle, there is not supposed to be a correct answer. The reason "Deadpool breaks the fourth wall" is that artists, following the instructions of writers, draw self-referential pictures that depict a man making statements about the pictures. The reason these pictures are interesting has to do with how we experience fiction.