There are a few reasons why viewing his cancer as an "engineering problem" is a helpful analogy; in fact, it can be helpful for dealing with any serious illness.
Working From a Familiar Construct
One way to grasp a new and difficult concept or learn something entirely new is to relate it to something familiar - go from the known to the unknown. This is used in teaching; we work from something you already know and move towards adding new information or branching to unrelated but similar concepts to aid in teaching the new concept.
Many people use a gardening analogy to deal with cancer - pruning and weeding in the garden is analogous to some of the treatments for cancer such as surgery and radiation. Chemotherapy is like spreading a spray to kill insects or weeds but can cause some harm to the grass or flowers. Sometimes the garden is so infested, people will take a radical approach to killing off a lot of it in order to wipe out the infestation.
Randy's expertise in engineering provided him with a similar construct to manage his disease. The human body and mind are sometimes described as an incredible engineering feat. The spread of disease can be viewed more dispassionately if one thinks of the internal body and organs as a computer motherboard, for example, with the body's lymphatic system as the buses that transport bits and byes between the motherboard and its peripherals (body's organs). Viewing his disease and its progression into different parts of his body this way could have helped Randy both understand and deal with it.
Distancing Oneself from the Illness
A major illness can take a severe emotional toll on anyone. Yet there are important decisions that must be made regarding treatment options, one's living situation, family members, etc. Our brains are capable of "compartmentalizing" information, to some degree, so we can face devastating news yet continue to function. Randy's use of an engineering problem quite probably helped him deal with the disease more dispassionately so he could make more effective decisions. He made many choices regarding his treatment, each of which came with its own side effects and potential to ensure either a longer life or a more humane and dignified end of life. You'll see that, after he learned that the disease had progressed to a more severe stage, Randy moved his family to Chesapeake so they'd be closer to his wife's family.
Find What Works for You
This is not to say that emotions aren't always present even if they've been pushed into the background. But, using familiar constructs to understand the disease can also help someone push those emotions into the background. This dual approach can help someone adjust to a difficult situation, learn more about it so they make better decisions, enjoy what remaining time they do have with family and friends, and, as Randy chose, help others in a similar situation.
I think it was helpful to Randy because he was an engineer--that's the way his brain worked, and how he could process dealing with his disease. Also, if you think about it, it's actually a great analogy, comparing the body to a machine. If something goes worng with the machine, it must be a mechanical, or engineering, problem. Even though it dealt with some extremely sensitive and heavy issues, The Last Lecture was often quite comical. I think calling his cancer an "engineering problem" was Mr. Pausch's humor bubbling to the surface once again. Using this understatement brought out humor. We all handle bad news differently. He just chose to handle it with humor.